N层实体框架没有结果但没有错误
我已经使用N-Tier实体框架VS2012创建了一个演示项目。
I have created a demo project using the N-Tier Entity Framework VS2012.
问题是没有返回的结果没有我要求的结果。
the problem is that there are no results returned no mather what i request.
没有抛出检测到的错误吗?
No Errors are thrown of detected?
这里有任何建议吗?
请确保调用AsQueriable()方法从后端请求数据。
Make sure to call the AsQueriable() method for requesting data from the backend.
N层实体框架支持本地和远程查询。虽然 context.Orders.ToList()仅返回客户端内存中已经存在的内容,您可以调用 context.Orders。 AsQueriable() .ToList()以便使查询在服务器上执行。
N-Tier Entity Framework supports both, local and remote queries. While e.g. context.Orders.ToList() only returns what’s already in client memory, you can call context.Orders.AsQueriable().ToList() to make the query to be executed on the server.
您可能还希望查阅位于 http://ntieref.codeplex.com/ 以获得一些逐步指导。
You may also want to consult the framework’s user guide found at http://ntieref.codeplex.com/ for some step-by-step guidance.