
To find the database status of the Microsoft SQL Server, you can execute below command.
select name, state_desc from sys.databases;

To find the database status of the Microsoft SQL Server, you can execute below command.
select name, state_desc from sys.databases;