This post gives one of the possible solution to the following error for SQL Server.
Most of the time we will be setting the database properties using SQL Server Management Studio, the GUI management interface. Somehow for some of the databases that have set to single user mode. When you right click those databases and choose properties, unfortunately, you have gotten the following error message.
“Database ‘Database’ is already open and can only have one user at a time”
At this point of time, you have no way to set anything on that database because SQL Server Management Studio keep popping out the error and refuses to bring you to the Properties page.
This is the time you need to utilize your SQL Query. Use the follow statements to turn your database back to multi user mode then you should be fine.
ALTER DATABASE WhateverDatabase
WITH ROLLBACK IMMEDIATE