Friday, December 21, 2012

The underlying provider failed on Open Error in Entity Framework Transactions


Error:
The underlying provider failed on Open
MSDTC on server 'XXXXX\\SQLEXPRESS' is unavailable."   at System.Data.EntityClient.EntityConnection.OpenStoreConnectionIf(Boolean openCondition, DbConnection storeConnectionToOpen, DbConnection originalConnection, String exceptionCode, String attemptedOperation, Boolean& closeStoreConnectionOnFailure)\r\n   at System.Data.EntityClient.EntityConnection.Open()\r\n   at System.Data.Objects.ObjectContext.EnsureConnection()\r\n   at System.Data.Objects.ObjectContext.SaveChanges(Boolean acceptChangesDuringSave)\r\n   at System.Data.Objects.ObjectContext.SaveChanges()\r\n  

Cause:
The error The underlying provider failed on Open is thrown while performing a transactional update using Entity Framework, if the MSDTC - Distributed Transaction Coordinator service is not started.

Resolution:

1. Open the services console Run -> services.msc
2. Find the service Distributed Transaction Coordinator
3. Make sure that this service is started.
4. If the service is not started, right click on the service and select Start

Search Flipkart Products:
Flipkart.com

1 comment:

kenzie jones said...

What do you want to convey? Nothing is clear in your post. Its not clears to me in the same way as you explained the points.If you explained something more then may be its understandable.
digital signature PDF