Reputation: 85
I can only have my database open in Visual Studio OR SSMS, but not at the same time. It is just the default DB that comes along with a new ASP.NET MVC solution (localhost connection). I attached the .mdf in sql server management studio and can see all the tables and query the DB just fine, but if that connection is open, I cannot run my web application simultaneously because I get an error about it being used by another process.
Is there any work around for this? It is very inconvenient to have to close out of VS and round-robin each time I need to query the DB in ssms.
Upvotes: 2
Views: 357
Reputation: 56
You should check whether your default DB is configured to allow multiple user access in the same time. In Management Studio, open database properties window. In Options page, check State -> Restrict Access field. It should be set to MULTI_USER, not SINGLE_USER.
Upvotes: 1