Learn more about SQL Server tools

mssqltips logo

Tutorials          DBA          Dev          BI          Career          Categories          Webcasts          Scripts          Today's Tip          Join

Tutorials      DBA      Dev      BI      Categories      Webcasts

DBA    Dev    BI    Categories


Visual Studio 2010 Overview Tutorial



One of the more difficult jobs that database professionals have to endure is maintaining installation and upgrade scripts for their databases from release to release. Many methods and tools are used such as loose SQL scripts run via SQLCMD or even writing a homegrown system to handle the creating and upgrading of databases. The biggest headaches are making sure dependencies among objects are observed so an install or upgrade does not fail and also to create scripts to update a database from a previous schema version to the latest. These processes are usually manual and they can be labor intensive. Unfortunately, this also means that they can be prone to error.


Visual Studio 2010 Database Projects offer excellent functionality to relieve developers of the mundane, manual tasks involved with maintaining databases. If your company licenses Visual Studio 2010 Professional or greater, you have the ability to create Visual Studio Database Projects. With these projects, you can add your database objects and the Visual Studio engine will figure out for you the dependencies between objects and differences between schemas and apply them which can mitigate some of the errors that can occur when working with scripts manually.

In this tutorial, we will examine the following steps in creating a Visual Studio 2010 Database Project:

  • Creating A New Database Project
  • Defining Database Properties
  • Defining Deployment Properties
  • Adding Tables To A Database Project
  • Adding Additional Objects To A Database Project
  • Working With Pre and Post Deployment Scripts
  • Setting Build and Deploy Properties
  • Building and Deploying a Database
  • Refactoring A Database After Deployment

Last Update: 9/10/2011

More SQL Server Solutions

Post a comment or let the author know this tip helped.

All comments are reviewed, so stay on subject or we may delete your comment. Note: your email address is not published. Required fields are marked with an asterisk (*).

*Name    *Email    Email me updates 

Signup for our newsletter
 I agree by submitting my data to receive communications, account updates and/or special offers about SQL Server from MSSQLTips and/or its Sponsors. I have read the privacy statement and understand I may unsubscribe at any time.


Monday, March 21, 2016 - 3:20:43 PM - Tom Back To Top

 I think Anne means 2013 or later since this is written for VS 2010.


Monday, March 21, 2016 - 2:58:30 PM - Anne Back To Top

Is there  a newer version of tutorial regarding this using Visual stuido 2003 or above, for I don't see something called schema view,  and newer version have a publish database, what is the difference between publich and deploy database?


Thanks .

Learn more about SQL Server tools