Backup and Restore a Database using the SQL Server Management Studio

,

Backup and Restore a Database using the SQL Server Management Studio

Backing up and Restoring your Database is one of the most important things you can do. Being able to do this quickly without affecting working users is also important – that is why it is recommended that backing up and restoring your database is done from SQL Server Management Studio.

Note: This is a better way to Backup/Restore than using the Navision client as it is quicker, safer and wont lock tables – see my other post (Backup/Restore using Navision Client). 


Backup Database

1. Log onto your SQL Server.
2. Open the SQL Server Management Studio.
3. You should be greeted by a ‘Connect’ dialogue box – I’m logging in with SA (default SQL Super), you can however use Windows Authentication. Chances are if you are a Super in NAV you can use your Windows Login to Backup/Restore.

4. Expand the ‘Databases’ folder. I’m going to use the ‘Test Database’ to try my backup.

5.  Right Click the ‘Test Database’ >> Tasks >> Backup

6. Choose your Backup location >> I have chosen C:Data. Also ensure you select ‘Disk’ as the Backup location. >> Then select ‘OK’.

Restore Database

1. Log onto your SQL Server.
2. Open the SQL Server Management Studio.
3. You should be greeted by a ‘Connect’ dialogue box.

4. Right Click the Database folder>> Restore Database…

 5. Make sure to select source as ‘Device’ and drill down to find your Backup file.  Now depending if   you want to Overwrite the Existing / or Creating a database you must choose the destination. In this scenario we are making a new database called ‘New Database’.

 6. You must also select the ‘Restore’ tick after finding the file. 

  7. You need to also determine where the Log and Data files will get stored when restoring your DB. As I want to keep the original Database intact (Test Database) I am editing the filepath to give the ‘New   Database’ a unique name so as not to overwrite the existing.

  8. Press OK and your done. 
  Andy
The following two tabs change content below.

Andy, Software Engineer

Andy is Software Engineer at Metaphorix