Hello!
- SQL Server Management Studio
- Visual Studio 2019 Preview
- Microsoft SQL Server Enterprise Core 2017
This is the first time I do this and I am not sure of how to create a SQL database that I can use in Visual Studio 2019.
I will tell the steps I have done and please correct me on the way.
Step 1:
I have created a database and named it: "database1". As seen I run a Query to find out the exact path location of the database:
C:\Program Files\Microsoft SQL Server\MSSQL14.MSSQLSERVER\MSSQL\DATA\database1.mdf
Step 2:
I am now trying to "Connect to Database" from Visual Studio 2019. As seen in the image below, I paste the Path to the database:
First I wonder if this is the correct way to do it?
Then, I wonder about the error messagebox that shows this message?
An attempt to attach an auto-named database for file "C:\Program Files\Microsoft SQL Server\MSSQL14.MSSQLSERVER\MSSQL\DATA\database1.mdf" failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
Thank you!