Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

ConnectionString in Asp.Net Core

$
0
0

In Asp.Net MVC 5 in the connection string we could tell EF to create the DB .mdf file inside the project, by adding this inside the connection string:

AttachDbFilename=|DataDirectory|\dbname.mdf

When I tried to do the same in Asp.Net Core I got an error telling me it couldn't create the db file in x folder path.

So how can I make it that the db file gets created inside my project folder or any other folder which I want?


Viewing all articles
Browse latest Browse all 9386

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>