Entity Developer (MySQL) and Reciprocal links issue
Posted: Thu 10 Jun 2010 20:05
Hi,
I have the following mysql ER Diagram:
http://screencast.com/t/M2ZlYjVkZTA
Here is how I'm making my EF model:
the User class will be inherited (Concrete Table) from Registry class
http://screencast.com/t/NzNiMTll
after that I'm getting the reciprocal links (User.userID -> Registry.CreatedBy, User.userID -> Registry.DeletedBy, User.userID->Registry.deletedBy) hightlighted by red color as shown below:
http://screencast.com/t/M2RlYjg1YjAt
the text of error is this:
1 Properties referred by the Principal Role User must be exactly identical to the key of the EntityType DataSourceModel.User referred to by the Principal Role in the relationship constraint for Relationship DataSourceModel.User_Registry. Make sure all the key properties are specified in the Principal Role. DataSourceModel1.edml
if I click on any "red" connection I'm getting this dialog:
http://screencast.com/t/NTI3OTJkM
after that I'm going to User->Mapping and change userID to be mapped to RegistryID column and then erasing the userID column from User class since it is no longer needed. AFter that I'm getting error, because now connections aren't mapped to anything, and I can't select a mapping at all.
see what I'm doing in a video (jing in flash):
http://screencast.com/t/ODY0YTQyM2Yt
I suppose to see here the registryID (since it is inherited from Registry table) and I don't see it
http://screencast.com/t/NzI5NDNlOW
in EF 4.0 (VS 2010 and 2008) and earlier version of MS SQL EF Designer I was able to select RegistryID and make such mapping.
If I go and modify the EDML file of Devart Designer - it crashes, after I try to reload the model
any Ideas?
I have the following mysql ER Diagram:
http://screencast.com/t/M2ZlYjVkZTA
Here is how I'm making my EF model:
the User class will be inherited (Concrete Table) from Registry class
http://screencast.com/t/NzNiMTll
after that I'm getting the reciprocal links (User.userID -> Registry.CreatedBy, User.userID -> Registry.DeletedBy, User.userID->Registry.deletedBy) hightlighted by red color as shown below:
http://screencast.com/t/M2RlYjg1YjAt
the text of error is this:
1 Properties referred by the Principal Role User must be exactly identical to the key of the EntityType DataSourceModel.User referred to by the Principal Role in the relationship constraint for Relationship DataSourceModel.User_Registry. Make sure all the key properties are specified in the Principal Role. DataSourceModel1.edml
if I click on any "red" connection I'm getting this dialog:
http://screencast.com/t/NTI3OTJkM
after that I'm going to User->Mapping and change userID to be mapped to RegistryID column and then erasing the userID column from User class since it is no longer needed. AFter that I'm getting error, because now connections aren't mapped to anything, and I can't select a mapping at all.
see what I'm doing in a video (jing in flash):
http://screencast.com/t/ODY0YTQyM2Yt
I suppose to see here the registryID (since it is inherited from Registry table) and I don't see it
http://screencast.com/t/NzI5NDNlOW
in EF 4.0 (VS 2010 and 2008) and earlier version of MS SQL EF Designer I was able to select RegistryID and make such mapping.
If I go and modify the EDML file of Devart Designer - it crashes, after I try to reload the model
any Ideas?