Where did the overload of DbQuery.Include() go that takes a lambda?

后端 未结 1 525
我寻月下人不归
我寻月下人不归 2020-12-24 10:02

I just declared some code-first models for a new project that uses EntityFramework.

public class BlogEntry
{
    public long Id { get; set; }
    public long         


        
相关标签:
1条回答
  • 2020-12-24 10:44
    using System.Data.Entity;
    

    It's in EF v4.1 and above, but you need a reference as it is an extension method.


    Edit (thanks to @EastonJamesHarvey)

    If using EF Core the import should be:

    using Microsoft.EntityFrameworkCore;
    
    0 讨论(0)
提交回复
热议问题