Database in SQL server in recovery mode

Database in SQL server in recovery mode

Check the SQL Server error log for related messages to see why the database is recovering. Common causes include:

  1. The database was restored with the NORECOVERY option from full, differential, and log backups but RECOVERY was not specified on the last restore. The solution in this case is simply execute RESTORE <your database> WITH RECOVERY; to rollback uncommitted transactions and bring the database online.

  2. The transaction log filled due to a large data modification operation and SQL Server is rolling the transactions(s) back to recover the database, which can take quite a bit of time. The error log will include recovery progress messages. It thats longer than you want to wait, it may be more expeditious to restore the database from backup(s). Be aware that if SQL Server is restarted during the database recovery process, recovery will restart from the beginning at service startup.

Well you could try this script

RESTORE DATABASE mydatabase WITH RECOVERY

SO this will finish the recovery process with no backup files. If you are getting an error message database in use. I think you shoudl try to stop the service, delete the databse and then Restore it with Recovery

Database in SQL server in recovery mode

Try this one :

Use [master]
GO

RESTORE DATABASE [DataBaseName] WITH RECOVERY

Leave a Reply

Your email address will not be published. Required fields are marked *