Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Entity framework migration "Table does not exist"

im new to entity framework , i created my entities from reverse engineering from a Mysql database that i have created in mysqlworkbench , and then i added some foreign keys in my entities and then i added a migration and tried to update my database but an error occured and it indicates that: "Table 'pidev.pidev.personal' doesn't exist". "pidev" is the name of my database. personal is a super class for two other subclasses "candiadte" and "employee" and im using TPH as inheritance strategy. PLZ i need some help.

like image 315
Haytham Avatar asked Nov 24 '15 13:11

Haytham


1 Answers

thank you all for your replies , I SOLVED the problem in the UP() and DOWN()method in the migration file i removed the name of the database in each line like this "DropPrimaryKey("pidev.personal");" ==> DropPrimaryKey("personal");

like image 170
Haytham Avatar answered Nov 10 '22 04:11

Haytham