Thanks to the solution posted here
Possible Causes
- The database could have become corrupted.
- There is not enough space available for the SQL Server to recover the database during startup.
- The database cannot be opened due to inaccessible files or insufficient memory or disk space.
- The database files are being held by operating system, third party backup software etc.
- There was an unexpected SQL Server Shutdown, power failure or a hardware failure.
In SQL Server Management Studio, run the below set of queries by putting proper database name
EXEC sp_resetstatus [Database Name];
ALTER DATABASE [Database Name] SET EMERGENCY
DBCC checkdb([Database Name])
ALTER DATABASE [Database Name] SET SINGLE_USER WITH ROLLBACK IMMEDIATE
DBCC CheckDB ([Database Name], REPAIR_ALLOW_DATA_LOSS)
ALTER DATABASE [Database Name] SET MULTI_USER
Thats all
No comments:
Post a Comment