views:

409

answers:

1

how to get child table along with the parent in entity framework using entity sql query for example var parentTable = "select value parentTable from parentTable as pt inner join childTable as ct on pt.key = ct.key";

doing this parentTable.childTable.count() returns 0.

so how can i get the childTable loaded along with the parent table?

A: 

You call Include() on your ObjectQuery, just like you do with LINQ to Entities. It's no different if you create your query using ESQL.

Craig Stuntz
thanks alot craig :)
gaurav