Restoring a Backup in SQL Server Management Studio

Since the creation of this blog over a decade ago, I always wanted to write about SQL because I think it is a skill that not many developers possess as most of them are using ORMs to work with relational databases. In addition, as data is more important today than ever, everybody should be able to perform queries to answer timely questions. But, before I write tutorials on SQL, the first step is showing how to restore a backup file in SQL Server Management Studio so we can dig into SQL queries and business/data analytics.

For this tutorial, I assume that you have SQL Server Management Studio installed on your computer. The sample database that is going to be restored is AdventureWorks. There are several versions of this database. But, for this tutorial, the AdventureWroksLT2019.bak (Lightweight) is the one chosen. Thus, download it to the C:/ drive of your computer so we can restore it. After saving the AdventureWroksLT2019.bak file on the C:/ drive, follow these steps:

Step 1

Within the SQL Management Studio, go to the Object Explorer and right-click on databases. Then, select “Restore Database…”

Step 2

In the Source section, select “device” and click on the button with the ellipses (…) to select the type of backup media.

Step 3

In the “Select backup devices” window select File in the dropdown menu and click the Add button.

Step 4

Navigate where the AdventureWroksLT2019.bak is located and select it. It is better to have the file in the C:/ drive in the root directory because it is easier to locate. Click OK after selecting the AdventureWroksLT2019.bak file.

Step 5

Press OK again to confirm this file and OK to restore the AdventurateWroksLT2019 database.

After restoring the database, you will get the message: “Database ‘AdventureWorksLT2019’ restored successfully”. Press OK and you are done.

Step 6

In the Object Explorer, you can open the AdventureWorksLT2019 database and confirm that there are tables created.

That is all! As I mentioned previously, this is the database that I will be using for some examples and tutorials for SQL Server.

Teylor Feliz
Teylor Feliz

Teylor is a seasoned generalist that enjoys learning new things. He has over 20 years of experience wearing different hats that include software engineer, UX designer, full-stack developer, web designer, data analyst, database administrator, and others. He is the founder of Haketi, a small firm that provides services in design, development, and consulting.

Over the last ten years, he has taught hundreds of students at an undergraduate and graduate levels. He loves teaching and mentoring new designers and developers to navigate the rapid changing field of UX design and engineering.

Articles: 183