Click here to Skip to main content
15,894,460 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Hi,
I want to add tables in edmx file in using vs2010 When I try to add a table/view/sp using the described method in the documentation (Right click in the model view or designer --> Update model from database...)...It doesn't add any table in edmx..Please tell me what the problem with that..I have gone through net all the tutorials seem to be suggesting nearly the same method to add tables. Please guide.

Thanks in Advance
Posted
Comments
Parwej Ahamad 4-Jul-11 11:12am    
Yeh... I think so sometime it creates problem, So most of time I deleted all tables from the designer and adding again all tables.

This possibly happens when the table or view you trying to add is already exists in the model. So instead of using add tab from the Update wizard[^],use the refresh tab and see the effect. You can also check either the table or view exists in the model by opening in the model file in xml editor.

For more take a look at this ADO.Net Team Blog[^]
 
Share this answer
 
Comments
Monjurul Habib 4-Jul-11 13:14pm    
nice answer, my 5.
srmohanr 16-Oct-13 8:26am    
Hi,
I am facing the same problem. But I have added primary key to that table. Even then I am not being able to add table to EDMX file.

Please help
Wonde Tadesse 4-Jul-11 14:32pm    
Thanks
touseef4pk 5-Jul-11 1:46am    
helpful tips..thanks it was problem due absence of primary key in the table.. My 5 here
Wonde Tadesse 5-Jul-11 7:37am    
You're most welcome

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900