1 / 16

Index

Index. What is DBCompare ? Why we need DBCompare ? How to use it ? Summary. What is DBCompare ?. It is a tool to keep two (or more) databases in synch.

tovi
Télécharger la présentation

Index

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Index • What is DBCompare ? • Why we need DBCompare ? • How to use it ? • Summary

  2. What is DBCompare ? • It is a tool to keep two (or more) databases in synch. • To achieve that one can run this tool by providing the schema details and it generates the user friendly reports about the differences in databases. • It also generates the alter script which can be applied in other database to clear out the differences. • It covers almost all of the database objects e.g. Tables, Stored Procedures, Indexes.

  3. Why we need it ? • In our daily life, software developers faces a lot of issues due to differences in the databases in different environments e.g. one application running fine in dev. environment might be failing in QA environment for just a simple reason that either some table is not present or some column is missing or in fact column length in QA environment is not same as in dev. environments. • It takes effort and manpower to identify those kind of issues which can be time consuming at sometime. This tool comes handy at that time and within minutes* it would generate the report and script for you to apply and remove those differences. • (*) – Run time takes the connection speed and database size.

  4. How to use DBCompare ? Brief: This project takes properties of two databases(need to synchronize ) as its inputs and generates different types of user friendly reports. Details: Lets have two databases, SCHEMA_1 SCHEMA_2 NOTE: You can make any one database as reference. In this example we are taking SCHEMA_1 as reference.

  5. DataBase Schema Details Department Table not present Extra column Has 2 foreign keys Size 20 Byte Age column absent SCHEMA_1 SCHEMA_2

  6. Index Details…. • There is a index on each schema with name DEPARTMENT_EMPLOYEE. • Index in SCHEMA_1 • Index in SCHEMA_2

  7. Procedures Details…. create or replace procedure "SP_INSERT_EMPLOYEEDETAILS" ( id IN VARCHAR2, name IN VARCHAR2, role IN VARCHAR2, department IN VARCHAR2, age IN VARCHAR2 ) is begin insert into EMPLOYEE values(ID, Name); insert into REGISTER values(Name,role,DEPARTMENT,AGE); end; create or replace procedure "SP_INSERT_EMPLOYEEDETAILS" ( id IN VARCHAR2, name IN VARCHAR2, role IN VARCHAR2, department IN VARCHAR2 ) is begin insert into EMPLOYEE values(ID, Name); insert into REGISTER values(Name,role,DEPARTMENT); end; SCHEMA_1 SCHEMA_2

  8. Report’s Phases Reports has two phases. • First give details on both schemas as well as differences between them. 2. Second phase provide you a script to synchronize the database.

  9. ….report’s phase…(1st phase) By exploring the reports you can find details of various components(tables , indexes , procedures , e.t.c.).

  10. ….report’s phase…(1st phase) Table’s Difference Report:

  11. ….report’s phase…(1st phase)

  12. ….reports Same way you can find other reports (table indexes List, table structure, etc.) just by navigating through the report directories of two different schemas (SCHEMA_1 and SCHEMA_2). Here we are attaching the some report files for your reference. 1. Table Indexes List for SCHEMA_1: 2. Table Structure for SCHEMA_1 : 3. Table Indexes List for SCHEMA_2: 4. Table Structure for SCHEMA_2 :

  13. Report Phase 2 DBCompare not only tell you about the differences in schema, but also it provides you a script to synchronize your databases.

  14. Summary. This is a wonderful tool to keep databases in synch in terms of DB structure. It’s a light weight tool and currently supports Oracle database, but could be easily extend to support any other database e.g. MySQL, Sybase etc.

  15. Thank you

More Related