How To Restore A Database In SQL Server 2012

Restoring a database in Microsoft SQL 2012 is very simple. To restore a SQL database you need the .bak file and sometimes the .trn file (depending on the type of backup that was taken).

Open Microsoft SQL Management Studio (It doesn’t have to be 2012. Athough this guide is aimed at SQL 2012, there should be enough information to do this with previous versions of SQL) and open the database engine of the SQL server that you wish to restore the database to. If the database is being restored over the top of a previous version, right click the previous database. Otherwise right click Databases. Click Tasks -> Restore -> Database…

Select the Device option and browse to the .bak file you want to restore from. Make sure the appropriate point in time is ticked underneith Backup sets to restore. Click the Options page on the left hand pane and tick the box to Overwrite the existing database (WITH REPLACE). If plan to restore incremental backups after this, select RESTORE WITH NORECOVERY from the dropdown, otherwise select RESTORE WITH RECOVERY. Click OK and the database will be recovered.

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)

Leave a comment

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