Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否有任何标准方法可以使用Entity Framework 5.0 代码优先方法来处理并发问题(当 2 个用户同时执行删除和更新操作时)?
请任何人帮助我如何使用 EF5.0 处理并发问题。
谢谢,
桑帕斯。
你试过抓OptimisticConcurrencyException吗?
OptimisticConcurrencyException
请参阅此示例:http ://www.asp.net/mvc/tutorials/getting-started-with-ef-using-mvc/handling-concurrency-with-the-entity-framework-in-an-asp-net- mvc-应用程序