This topic contains the following subtopics:
Resolve Schema via a Generated SQL Script
Once a schema comparison job completes, you can choose to run synchronization commands that match the schemas to each other. The synchronization process generates CREATE, DROP, and ALTER statements, and stored procedures on the source and target data sources.
To generate a SQL synchronization script
- On the Results tab, click Sync All in the Resolution column of the Comparison Results table. A synchronizing script is produced in another window.
The script can be modified manually, executed as needed, and saved at any time.
Execute a SQL Synchronization Script
You execute SQL synchronization scripts using commands in the Run menu or the command icons located along the top right of SQL Editor.
When an SQL file is open in the workspace, select it and choose a database and an associated catalog on which you want to execute file using the drop down menus in SQL Editor. You can click the execute icon to execute the code on the specified database and catalog, start a transaction or commit a transaction, or modify the SQL session options prior to execution.
To execute SQL code
- Open the SQL file you want to run. Make sure that it is associated with the correct database.
- Click the Execute SQL icon.
DB Change Manager executes the code on the data source you specified and displays the results in the same tab or in a new tab.
To execute a transaction
- Open the transaction file you want to run. Make sure that it is associated with the correct database.
- Click the Start Transaction icon.
DB Change Manager executes the transaction on the data source you specified.
To commit a transaction
- Open the transaction file you want to commit. Make sure that it is associated with the correct database.
- Click the Commit Transaction icon.
DB Change Manager commits the transaction on the data source you specified.
You can set transactions to auto-commit prior to execution on the SQL Execution node of the Preferences panel.
The synchronization script generation process does not support all object parameters. You should add the following object parameters, as needed, after a synchronization script is generated: fillfactor, consumers, allow_dup_row, and statistics.
Configure an SQL Session
The SQL Session Options dialog provides configuration parameters that indicate to DB Change Manager how to execute code in the development environment.
To modify SQL session options
- In the SQL Editor, click the Set SQL Session Options icon.
The SQL Session Options dialog appears.
- Click on individual parameters in the Value column to change the configuration of each property.
- Click Finish.
The session options change and DB Change Manager executes the code as specified when you launch the script.
After running the job, you can generate a job report that summarizes the archived configuration information. You can also generate job reports for any archive versions that exist in the system. Click View Report on the Results tab. For more information, see Creating a job report.