I have an MVC 2 project where I recently consolidated the auto-generated membership/roles database with my primary database. I have an EF4 model generated from the primary database and it contains a table called Books. Now that I've consolidated the two, I setup relationships between Books and aspnet_Users so that I can see each user's books.
开发者_高级运维The problem is that I want to update my EF4 model so that it represents this relationship, but I want to keep all of the generated membership code.
Is there anyway to do this?
The solution is to not map the membership tables. Store the GUID or email address in another table. See the question comments for the detailed answer. Thanks @RPM1984 and @Craig Stuntz.
精彩评论