I have generated xxxModel.Context and xxxModel template (in Models) from an existing database using EF 4.1 on ASP.Net MVC 4 application. After that when I build the project it gives the error for all the Model classes (POCO) saying “The type file name already contains a definition for memeber variable name“. Where am I going wrong?

Thanks for help.
Clearly the file
DESE.cs(and others) already contains identically named classes with properties – which are clashing with the types generated by EF.CC_Names.cs, for example, is being output by a text template – so I’m assuming you’ve got more than one code-generation strategy going on here from the same database.And then you also have issues where you’ve re-declared the partial class
CorpCostEntitiesagain in another file with a different base to the one set by the EF code generator.I think you might need to decide whether you want to use edmx code generation or the text-templating approach and stick to it 🙂