BackUp a SQL Server DataBase

Now we are going to learn how to backup a database in SQL Server 2008R2.

First why we need a backup:

Before doing any major operations in the database, it is always a good practice to backup the database.

If something goes wrong in the database, you can simple restore the backup that you have taken and you can able to undo the database easily to a earlier stage.

Step 1: Open SQL Server Management Studio. Right Click on the Database. Select ‘Tasks’. Select ‘Backup…’

Image

Step 2: Now the BackUp Database window opens and Select the Source Database. Select the Recovery model as ‘FULL”. In the destination Text area, Select Backup to Disk. Click on ‘Add’ button and choose the directory and file name that you want to have your backup. Example: “C:\SQLDB\AdventureWOrks20008R2.bak”

“.bak” is the file format for SQL Server database backup files.

Image

Step 3: Click on the “Options” tab in Back Up Database window and mostly I will leave everything to default settings here.

Image

Step 4: Click OK. You should get a prompt like below after the database is successfully backed up.

Image

Now you can go and see the “.bak” backup file in the directory you have chosen. Thats it. You have backed up a database using SQL Server.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s