Tool Mentor: Reverse Engineering Databases Using Rational XDE Developer
This tool mentor describes the use of reverse engineering in the Rational XDE developer software tool to generate a Data Model from an existing database schema or DDL script file.
Tool: Rational XDE Developer
Relationships
Related Elements
Main Description

Overview

This tool mentor describes the use of reverse engineering in the Rational XDE (TM) software tool to generate a Data Model from an existing database schema or DDL script file.

The following steps are performed in this tool mentor:

Reverse Engineer a Database

In Rational XDE, you can build a model of the physical database design through reverse engineering of the database or a Data Definition Language (DDL) file. Reference: helpbook iconBuilding Data Models by Reverse Engineering .

You initiate the reverse engineering process using the Rational XDE data modeling Reverse Engineering Wizard.  (See helpbook iconReverse Engineering DDLs or Databases .) The Reverse Engineering Wizard reads the database schema or DDL and creates:

  • A package containing the tables, columns, constraints, relationships, stored procedures, and views. See helpbook iconDesigning Data Models .
  • A package containing the domains. See helpbook iconDomains .
  • A database containing a realization relationship for each table. See helpbook iconRealize Relationships in Data Modeling .

To reverse engineer a database, Rational XDE must be able to establish a connection to the database. (See helpbook iconConnecting to Database Management Systems .)  Note that the results of the reverse engineering process might vary with each DBMS.

Refer to the following topics for further details on reverse engineering databases for a specific DBMS:

  • helpbook iconOracle Database Reverse Engineering
  • helpbook iconSQL Server Database Reverse Engineering
  • helpbook iconSybase Database Reverse Engineering
  • helpbook iconDB2 Database Reverse Engineering

For more information on establishing database connections for a specific DBMS, consult the following topics in the Rational XDE online Help:

  • helpbook iconOracle Database Connections
  • helpbook iconSQL Server Database Connections
  • helpbook iconSybase Database Connections
  • helpbook iconDB2 Database Connections

Transform Tables to Classes <optional>

Once a database has been reverse engineered to create a model of the physical database design, you can optionally decide to transform the tables into classes that can become part of the logical database design in the Design Model or in a separate Logical Data Model. (See helpbook iconLogical Data Model .) You can transform one table or all the tables contained in a package or realized by a database. (See helpbook iconTransforming Tables to Classes .) The package must contain all of the participants in a relationship to transform that relationship to the Logical Data Model.

For additional details on designing and modeling a database, see Tool Mentor: Designing and Modeling Databases in Rational XDE.

Refer to the following topics in the Rational XDE online Help for further details on the table-to-class transformation process:

  • helpbook iconTable to Class Transformation
  • helpbook iconTable to Class Transformation Mapping
  • helpbook iconTransforming Tables and Classes

Manage Changes to the Model and the Database

After a Data Model has been created through the reverse engineering process, updates to the Data Model and database must be controlled and managed. Rational XDE provides a Compare and Synchronize feature to assist the database designer in managing change. (See helpbook iconComparing and Synchronizing in Data Modeling , Tool Mentor: Managing Databases in Rational XDE.) Use of the Compare and Synchronize feature is recommended over periodic reverse engineering, since using the reverse engineering process multiple times on the same model can cause duplicate tables and relationships in the Data Model.