Entity framework 可以一次查询多个表返回来对应的list 里吗
Entity framework 可以一次查询多个表返回到对应的list 里吗?
Entity framework 可以一次查询多个表返回到对应的list 里吗?
有时候要查不同的表,一个个查询的话会多次访问数据库,有办法在一次访问数据库获取到多个表吗?
------解决方案--------------------
Because an open connection to the database consumes a valuable resource, the Entity Framework opens and closes the database connection only as needed.
http://msdn.microsoft.com/en-us/library/cc853327%28v=vs.110%29.aspx
Entity framework 可以一次查询多个表返回到对应的list 里吗?
有时候要查不同的表,一个个查询的话会多次访问数据库,有办法在一次访问数据库获取到多个表吗?
------解决方案--------------------
Because an open connection to the database consumes a valuable resource, the Entity Framework opens and closes the database connection only as needed.
http://msdn.microsoft.com/en-us/library/cc853327%28v=vs.110%29.aspx