Can the automatically generated .mdf database in App_Data be used in production?

2

Can the database automatically generated within the App_Data folder in projects Asp.Net MVC and Web-Api be used in production or is it a test-only basis?

    
asked by anonymous 15.07.2014 / 13:45

1 answer

1

The problem with using this database is that AttachDBFilename is a unique property of SQL Server Express, it works only as a user instance and can not be used over the network.

If you have control over production SQL Server you may get the mdf and ldf files to attach to your SQL Server server, however if you use a shared hosting this is usually not an option, in this case going it would be easier for you to generate a script to create the same tables.

    
15.07.2014 / 14:58