Pomelo.EntityFrameworkCore.MySql icon indicating copy to clipboard operation
Pomelo.EntityFrameworkCore.MySql copied to clipboard

Impossible to scaffold MySQL 5.0.95 database

Open sneps85 opened this issue 2 years ago • 1 comments

When scaffolding a MySQL 5.0.95 database i get the following error:

Unknown table 'REFERENTIAL_CONSTRAINTS' in information_schema

Seems legit to me, as 'REFERENTIAL_CONSTRAINTS' table is only available in MySQL 5.1.* and above. How can I generate my entities for the old databse using .net core 6.0?

sneps85 avatar May 04 '22 13:05 sneps85

I'm sure you have good reasons to still use 5.0, but that was released in 2005 and EOL was in 2012 (about 10 years ago). The easiest way to scaffold an old database would be to dump the database and restore to a newer version on your development machine that the scaffolding can work against. Otherwise you can try to add a custom design time service, see https://github.com/PomeloFoundation/Pomelo.EntityFrameworkCore.MySql/issues/1584#issuecomment-990967123.

mguinness avatar May 04 '22 15:05 mguinness