Compare Schemas Using Toad
Compare Data, Objects, and More
Compare Schemas
Note: You can compare schemas in the Base Edition, but definition files and sync scripts are only available with the DB Admin Module or Toad for Oracle Xpert Edition.

To compare schemas
1.    Select Database | Compare | Schemas.
2.    Complete the fields as necessary. 
Schemas Tab
Description
Reference Schema (Source)
Select a schema connection or schema definition file to use as the basis for comparison. If you execute the sync script, the target schema is updated to match the reference source.
Tip: If you select Create Schema Definition File, you can use variables in the filename. By default, Toad includes the %DATEFILE% and %TIMEFILE% variables, which inserts the current date and time into the filename when it creates the definition file.
Targets and Output
Click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=1c0e15d2-0ed5-4f39-b11c-b884b2b1788b in the Live Schemas or Def Files field to add a target schema for comparison. You can repeat this step to compare multiple target schemas to the source.
Tip: Right-click a target to edit it, delete it, or switch it with the reference source.
Options Tab
Description
Object Types to Compare
Select the object types you want to compare. Reducing the object types reduces the amount of time it takes to complete the comparison.
Tip: Right-click to select or clear all fields.
Object Set Tab
Description
Specify Object Set
Select to determine specific object sets to compare. This lets you limit your comparison even more than the Options tab.
Click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=2b778fd2-e395-4d4a-a54a-93133582d329 to add an object set. If you already have objects loaded, a confirmation dialog ask you if you want to clear the grid before loading the new objects. Click Yes to start over, or No to append the new objects into the grid.
3.    Click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=fed4f751-7cd4-4c5d-91ae-0d693701ba76 to execute, or save or schedule the selections as a Toad action.
4.    Review the differences on the Results tab.
If you want to...
Complete the following:
Show the sync script for selected objects.
Select the objects and click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=eae03ac0-9a43-4c13-990b-c45c88e54051.
View the differences for one object
Select the objects and click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=3308d28d-5aa1-42c0-9541-2de35597f300.
View the differences for another target
Select the target in the Target Schema field (only applicable if you selected more than one target for comparison).
5.    To sync the schemas, select the Sync Script tab and click http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=2b7405c7-ac0f-4f81-9867-c1f4bcdc83bb to execute immediately from the Editor or http://documents.software.dell.com/toad-for-oracle/12.1/guide-to-using-toad-for-oracle/chapter-2-toad-without-code/compare-data-objects-and-more/snippets/image.ashx?id=b093e40b-6e2a-4e88-9d31-ecc8549b50a6to schedule its execution.
Caution: Review this script thoroughly before executing it to prevent unintentional data loss.



Comments

Popular posts from this blog