Problem analysis:
I found this error today during the EF Core database migration, my project just copied and pasted the configuration file, and since then I found that the database configuration file json was the culprit.
I found out that the .json file was not set to “copy to output directory”, so the program could not find the data file at runtime. The following figure shows the correct configuration.
This problem is generally divided into two cases: 1.
1, the database link in the database file is not correctly configured .
2, json configuration file is not correctly set to “copy to output directory”, exactly what I mentioned above.