Visual Studio DataBase Project - PowerPoint PPT Presentation

About This Presentation
Title:

Visual Studio DataBase Project

Description:

Visual studio database project assists you in designing deployment dialogue(s) in a compact time and with more manageable steps. – PowerPoint PPT presentation

Number of Views:469
Slides: 22
Provided by: clariontech123
Category:

less

Transcript and Presenter's Notes

Title: Visual Studio DataBase Project


1
Visual Studio
DataBase Project
2
Overview
  • Visual studio database project helps you in
    creating deployment script(s) in short time and
    with simpler steps.

3
Manual Process
  • List out all the database related changes that
    needs to be deployed.
  • Right click on database object in SQL Server and
    create the script based on the need like
    Create/Alter/Drop script.
  • Execute all those scripts on Targeted database
    one-by-one.
  • Note Manual Process might miss out the dependent
    object script(s).

4
Process using Database Project
  • Create Database Project from File gt New project gt
    Sql Server(Template).
  • Right click on project from solution explorer and
    select Schema compare.
  • Configure and Select Source and Target
    database.
  • Click Compare button in the Schema Compare
    Window toolbar to start the comparison process.
  • When the comparison is completed, select the
    appropriate schema changes.
  • Update the schema directly by clicking on
    Update button or generate the script from
    Generate Script button and then execute it on
    Targeted database.

5
Advantages of using Database Project
  1. Reduce Manual work
  2. Save deployment time
  3. Easily deployable in any conditions
  4. Helpful in versioning db object / deployment
    scripts
  5. Automatically detects dependent objects
  6. It will cover all schema related changes like
    Table, Column Data type/size change, Constraints,
    User defined objects, View, Indexes, properties
    etc

6
Disadvantage of using Database Project
Prerequisite
  1. Can be time consuming due to server traffic/speed
  2. Active connection can interrupt schema comparison
    process
  1. Visual studio ( 2015 / 2013 / 2012 / 2010 / 2008
    / 2005 )

7
Lets get started
8
  • Select schema changes from the comparison list
    and click on Generate Script
  • Select Source and Destination database(s)
  • Create Database project

Start Comparison
Generate Script
  • Create Solution
  • Start Comparison
  • Generate Script
  • Compare schema
  • Database selection
  • Start Comparison for both schema
  • Select Schema compare object

9
Step 1
Create Database Project
10
Step 2
Right click on project from solution explorer
and click on Schema Compare
11
Step 3
Select respective Source and Target db
12
Step 3
Configure Source and Target db
13
Step 4
To start comparison bw both schema, Click on
Compare
14
Step 4
Comparison will list out the differences found in
both schema
15
Step 4
Comparison will list out the differences found in
both schema
16
Step 4
Select the respective db objects
17
Step 5
Click on Generate Script
18
Step 5
Generated Script based on selected db objects
19
Step 5
Generated Script based on selected db objects
20
Step 5
Generated Script based on selected db objects
21
Thank You
Write a Comment
User Comments (0)
About PowerShow.com