Sunday 17 January 2016

How to fix the Error: "Warning: you must recover this database prior to access."

Warning

Mainly cause of this Warning “Warning: you must recover this database prior to access.” is the corruption of transaction log file for the database. For recovery of this database you need to follow these steps :




1) Open ‘SSMS’ with ‘SA’ or ‘Super’ credentials.

2) Go to ‘Databases‘ and select your respective  suspected database.

3) Right click on that database and select ‘New Query’.

4) Run the following commands sequentially one by one.

  • 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


5) After successful execution of all commands your database is recovered and ready for use.

Enjoyed the topic, Please do subscribe to our newsletter to get updated with every post without a miss.

Thanks for reading,

Shubin Dongre

No comments:

Post a Comment

Microsoft Dynamics NAV Security Notice Confirmation Dialog

                                     Hello Everyone,  Ever came across the following confirmation dialog message :         ...