4

So my problem is, I added a extra column in My one of the table in database in SQL and i wanted to reflec that change in my MVC project. So what i usually do is update the model from the database and it works all the time.But this time it didnt worked so i thought let me delete the table from Project1Model.Store>Tables/Views from the EDMX Model Browser and then update the model from Database(which worked in past for me). But by mistake deleting the SessionDetail table i deleted the sysdiagram table from tables/Views.

Now i dont have sysdiagram table in my Tables/Views section but i can see that table in diagram and in EntityTypes. I tried generating model from databse but didnt worked. I dont want to create Database from Model because i know i deleted something from my model and dont want to effect my database which is fine(let me know if i am wrong this the right way).

I still get this error after built the solutions. Let me know how i can recreate the sysdiagram table in my Table/Views section.

Thanks in Advance. -Arpan

tereško
  • 58,060
  • 25
  • 98
  • 150
arpan shah
  • 277
  • 2
  • 18

1 Answers1

0

I had the same error and went to the .edmx and deleted the sysdiagram table and everything worked well.

I initially had been connected to a database that had a database diagram but later I connected to a copy of that database but without a diagram which I guess was the source of the problems.

So to conclude first check if you have a diagram in the db, if not either recreate it and update your model from db, alternatively completely delete sysdiagrm table from your model.

Harry
  • 1,765
  • 1
  • 12
  • 12