Ion cojocaru
Ion cojocaru

Reputation: 19

How to add the connected SQL Server database to the solution folder?

I've created a small ASP.NET MVC application and used a SQL Server database. I saw that the database was not moved to the Solution folder, so if understood correctly, the application won't work on other computers/servers.

Is it possible to move somehow the database to the project without losing the connection with the application?

Please help! Thanks in advance!

Answer:

The problem was solved with the solution from

https://www.codeproject.com/Questions/441590/How-to-add-existing-database-in-app-data-folder-in

Upvotes: 0

Views: 171

Answers (1)

TomTom
TomTom

Reputation: 62093

No. Seriously. ANY serious setup will have a database server and somone will apply a backup of the database you provide there. Unless you write toy applications, you NEVER employ the databsae on the same machine and "in the folder" - this works for development, it is not how SQL is deployed in the real world of larger controlled applications.

And get used on how to make upgrades to that database via some sort of change script mechanism.

Upvotes: 2

Related Questions