Hi folks,
i'm trying to eager load some child entity, and when I try to add the Include() method, i'm getting a compiler error (ie. it can't find it).
er ... can anyone help me out on this one, please?
Hi folks,
i'm trying to eager load some child entity, and when I try to add the Include() method, i'm getting a compiler error (ie. it can't find it).
er ... can anyone help me out on this one, please?
As far as I can tell, Include() is not a method of IObjectSet, not of any interface it extends:
http://msdn.microsoft.com/en-us/library/dd642094(VS.100).aspx
Include
is a member of ObjectQuery (it also returns a ObjectQuery), so you need a ObjectQuery object to start with.
Have a look at this post by Julie Lerman Agile Entity Framework 4 Repository Part 5: IObjectSet and Include