Pages

Wednesday, July 17, 2013

OptimisticConcurrenyException was unhandled by user code in MVC

Exception

OptimisticConcurrenyException was unhandled by user code

Store update, insert, or delete statement affected an unexpected number of rows (0). Entities may have been modified or deleted since entities were loaded. Refresh ObjectStateManager entries.


Cause

We are trying to update a data which is not present and an SqlException is thrown which is unhandled by our code.


No comments:

Post a Comment