Friday, February 11, 2011

The EntityContainer name must be unique. An EntityContainer with the name 'xxxxx' is already defined.

This issue arises if you have two models in a project that have the same schema.

Even if you delete the one of the model, make sure that the reference to the original assembly that is still in the client application's BIN folder is deleted to fix this error.

Entity Framework was attempting to load the metadata files from both assemblies and detected the conflict.

Cleaning the project didn't fix the problem. The leftover assembly was still there.. that had to be deleted (dll and pdb file manually)

1 comment:

Unknown said...

Thanks for saving my life! Had to delete the files manually, damn you Clean Solution". VS2010.

Post a Comment