Entity Framework - Querying from ObjectContext vs Querying from Navigation Property
问题 I've noticed that depending on how I extract data from my Entity Framework model, I get different types of results. For example, when getting the list of employees in a particular department: If I pull directly from ObjectContext, I get an IQueryable<Employee> , which is actually a System.Data.Objects.ObjectQuery<Employee> : var employees = MyObjectContext.Employees.Where(e => e.DepartmentId == MyDepartment.Id && e.SomeCondtition) But if I use the Navigation Property of MyDepartment, I get an