c# - Entity Framework 4.0 mapping issues -



c# - Entity Framework 4.0 mapping issues -

i'm getting next error when trying run solution using entity framework 4.0 , wondering how alter mapping settings right it:

problem in mapping fragments starting @ line 588: must specify mapping key properties (userdatas.id) of entityset userdatas

to give background - created tables shown below modified/created date/by , id columns in each of them, decided pull them out abstract userdata , utilize inheritance instead. since changed it's gone pot!

does have pointers i'm going wrong? i've been using design view show below (the gui) , feels i've nail brick wall.

my db.edmx design view looks this, , clicking on error takes me variables table shown below, error repeated other tables inherit id (please ignore links other tables - didn't want post whole big db schematic):

many thanks.

sounds mis-using oo inheritance here. because objects share items same property names doesn't mean inherit base. example, inquire in modle if tag userdata? suspect phrase improve tag has userdata points containment rather inheritance. recommend setting mutual iuserdata interface each object implements interface distinctly. in case, mapping move properties userdata interface underlying classes (as configured originally). while may able mapping work inheritance model, queries complex both linq , tsql perspective.

c# entity-framework-4 edmx

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -