Recover deleted Azure SQL Database
Yes, it’s true. You can indeed recover deleted Azure SQL database during the retention period for the SQL Database automated backups for your service tier. To know more about automated backups and retention period refer this post.
Database recovery is possible but there are a few caveats like: You can restore the deleted database only on the same server which had original database before it was deleted. You can change the Database name to original or choose a different database name. By default Azure portal suffix the Original database name with timestamp when the DB was dropped\deleted.
Important to note: If by mistake you deleted\dropped Azure SQL Server Instance, all related databases will also be dropped and won’t be able to recover deleted Azure SQL Database.
Steps to Recover deleted Azure SQL Database
Let’s take a look at the steps to recovery DB using Azure portal: First login to the portal and select the SQL Server Instance which originally hosted deleted DB.
Now move to the end of page & find an option to list down all deleted databases which you can recover.
Choose the database which you want to recover.
Choose the database name for newly recovered database and press Ok. that’s it viola! Once the recovery is complete your database will come online and you’ll get this notification on your new azure portal. Like this:
Let’s verify after connecting to SSMS:
If you want to move it to another server, you can use Copy database feature explained here. 🙂
Don’t have Azure account? click here to get trial.
feel free to leave a comment. 🙂