Deploy changes from source control
Last modified: March 28, 2025
Schema Compare allows you to deploy the changes from/to the source control using Schema Compare.
Note
Source control versions cannot be modified directly.
Schema Compare doesn’t allow comparison of working folders. Try using Scripts Folders instead.
Deploy changes using source control as source
When a source control version is a source, a synchronization script can be executed directly against the target database.
1. In the upper-right corner of the Start Page or on the toolbar, click New Schema Comparison to open the New Schema Comparison wizard.
2. On the Source and Target page of the wizard, select Source Control as a source type, the required repository, and the revision from version control. If you want to select a specific revision from the source control history, click Select a specified revision and follow the instructions in the Select a source control version.
4. Under Target, select Database as a target type, a destination database you want to compare, and a server.
5. Optional: On the Options page, customize the default comparison settings.
6. To launch the comparison, click Compare.
7. By default, the Schema Comparison document selects all the objects for synchronization. To exclude some objects from synchronization, clear the checkbox next to the corresponding objects.
To start synchronization, click Synchronize objects to the target database at the top of the document.
8. On the Output page of the Schema Synchronization Wizard that opens, select Execute the script directly against the target database and click Synchronize to deploy the database to the specified revision.
Deploy changes using source control as target
When source control version is a target, Schema Compare creates a synchronization script that can be saved to a file.
1. In the upper-right corner of the Start Page or on the toolbar, click New Schema Comparison to open the New Schema Comparison wizard.
2. On the Source and Target page of the wizard, select Database as a source type, a database you want to compare, and a server.
4. Under Target, select Source Control as a target type, the required repository, and the revision from version control. If you want to select a specific revision from the source control history, click Select a specified revision and follow the instructions in the Select a source control version.
5. Optional: On the Options page, customize the default comparison settings.
6. To launch the comparison, click Compare.
7. By default, the Schema Comparison document selects all the objects for synchronization. To exclude some objects from synchronization, clear the checkbox next to the corresponding objects.
To start synchronization, click Synchronize objects to the target database at the top of the document.
8. On the Output page of the Schema Synchronization Wizard that opens, select Save the script to a file, specify the path to the file that will store the script, and click Synchronize.
Optional: You can select the Open script in the internal editor checkbox to open the script in the editor and view and modify it to your needs. The Append timestamp to the file name option is selected by default. It adds date and time to the file name. To exclude it from the name, clear the checkbox.
Want to find out more?
Overview
Take a quick tour to learn all about the key benefits delivered by Schema Compare for SQL Server.
All features
Get acquainted with the rich features and capabilities of the tool in less than 5 minutes.
Request a demo
If you consider employing this tool for your business, request a demo to see it in action.