How do you construct a LINQ to Entities query to load child objects directly, instead of calling a Reference property or Load()

后端 未结 3 504
面向向阳花
面向向阳花 2020-12-02 14:22

I\'m new to using LINQ to Entities (or Entity Framework whatever they\'re calling it) and I\'m writing a lot of code like this:

var item = (from InventoryIte         


        
3条回答
  •  暖寄归人
    2020-12-02 15:11

    AFAIK, For silverlight(domain services) adding [Include] attribute to right place(over navigation property in metadata) is enough https://stackoverflow.com/a/5332188/413032

提交回复
热议问题