Skip to content

Import Databases

Dr John Tunnicliffe edited this page May 11, 2019 · 3 revisions

Importing databases into SQL Server Data Tools (SSDT) is simplicity itself and only takes seconds. However, sorting out the links to other databases and bad code thereafter can be difficult.

First, create a new Visual Studio SQL Server Project as shown below:

Create new Visual Studio SQL Server Project

Then select Import Database

SQL Server Project - Import database

Using the dialog, enter server on which the database resides, select the database and click Import.

SQL Server Project - Import database options

As you will see from the next dialog, the import is very, very comprehensive and covers every object type that can possibly be in a SQL Server database. The import is also very fast, taking seconds to import every object in the database, even for large databases!

SQL Server Project - Import DB

Once completed, in the Visual Studio Solution Explorer you will see a folder for every schema found in the source database. Below each folder will be an optional number of folders called Tables, Views, Stored Procedures etc.

SQL Server Project - Imported project

Clone this wiki locally