Schema Compare Results Window

This window displays the results of a schema comparison in several ways:

  • Tree control summary format

  • Text grid details view (Attributes tab)

  • Object Definition changes view (Object Definition tab)

  • SQL difference view (Update SQL tab)

The top portion of this window also includes several toolbar buttons.

Opening the Schema Compare Results Window

After you provide the Schema Compare Source and Target Dialog with the source and target database connections or Oracle Database Project Version 2 database projects, the Schema Compare Results Window opens. You can open the Schema Compare Source and Target Dialog from the Visual Studio Tools menu, from the Project node in a Oracle Database Project Version 2, or the context menu for a Server Explorer Data Connection node, described in Menu Options.

Using the Schema Compare Results Window

The Schema Compare Results window appears similar to the following:

The controls in the Schema Compare Results Window are as follows:

Control Description

Source to Target toolbar button

Switches the source and target database schemas.

Refresh toolbar button

Clears the results and re-runs the schema compare.

Update Target toolbar button

This will update a target Database Connection or Oracle Database Project Version 2 project so that the target schema will match the source schema.

Generate Script toolbar button

This will generate a deployment script (a diff script) and open it in an Oracle Query Window associated with the target Oracle Database connection. The script can be saved as a file and can be run against the target database to upgrade the target schema to match the source schema. This window contains an Execute Query toolbar icon that will run selected SQL against the Oracle Database Connection.

Note: Generate Script button is disabled when target is type Oracle Database Project Version 2.

Options button

The options button reopens the Schema Compare Source and Target Dialog with the settings selected when Schema Compare was previously launched. Clicking the OK button on the dialog clears the Schema Compare Results Window and re-runs the schema comparison.

Filter button

The Filter button opens a drop-down list allowing you to choose the filters that control the type of results displayed. The filter takes effect immediately after you make a selection.

Difference hierarchy tree

Displays various levels of the schema hierarchy, indicating differences between the source and target at various points in the hierarchy. You can expand nodes and drill down until you get down to individual schema objects.

Action checkbox

Schema objects or schema object types that have the Action checkbox selected will be included when the Update Target toolbar button or the Generate Script toolbar button is used. The topmost checkbox can be used to select or de-select all checkboxes.

Update SQL tab

Shows the SQL needed to modify the target schema to match the source schema for a selected schema object or any of its child nodes, for example, a table or any of its columns. For higher level nodes in the schema comparison hierarchy, this tab will be blank.

Attributes tab

Displays a grid showing differences between source and target schema objects. For example, if a table column has been changed from a type NUMBER(5,1) to a NUMBER(7,1), you can see this by clicking on the column node in the differences hierarchy and then viewing the Attributes tab. For higher level nodes in the schema comparison hierarchy, this tab will be blank.

Object Definition tab

Displays the difference between the source and target for the selected schema object, using SQL code that might be used to create the object (such as, CREATE TABLE). This tab is split vertically, showing both the source and target SQL with the mismatched lines highlighted. For higher level nodes in the schema comparison hierarchy, this tab will be blank.