Prev | Next |
Import Database Schema
The power of model-based engineering is the ability to visualize, analyze and design all aspects of a system. Being able to view the database schemas alongside other models of a system provides great clarity and reduces the chance of error. Enterprise Architect can reverse engineer a DBMS schema and its objects into a model under a number of different standards, including UML, Information Engineering and IDEF 1X. A wide range of database objects are supported including Tables, Views, Procedures, Functions and Sequences. Enterprise Architect communicates with the DBMS via ODBC, can import a schema via this connection, and can synchronize the model with the live database if it is changed.
Once the schema is in Enterprise Architect, the database objects can be traced to other elements, ensuring the integrity of design and architecture. When systems target multiple DBMSs, these can all be reverse engineered into a model and elements and datatypes can be compared between these models. The sophisticated reporting engine can produce high quality documentation, including data dictionaries, diagrams and relationships back to other models such as architecture and information requirements, and ultimately to business goals and drivers.
Database schema information can be imported via the Database Builder or from the 'Code' ribbon.
Import Database Schema
Step |
Action |
See also |
---|---|---|
1 |
Open the Database Builder. |
The Database Builder |
2 |
Load or create a Data Model. |
|
3 |
The 'Import DB Schema from ODBC source' dialog displays, showing the details of the current active database connection. |
The Import DB Schema from ODBC Source dialog
Option |
Description |
See also |
---|---|---|
Database |
This field shows a description of the current ODBC connection, in the format: dbms.database_server.database_name If necessary, click on the button and, on the 'Machine Data Source' tab of the 'ODBC Select Data Source' dialog, select an alternative ODBC connection. |
|
Import to |
This field shows the target Package that the new objects will be saved to. If you want to specify a different Package, click on the button and select an alternative Package. |
|
Only include objects from Schema(s) |
If the database type supports multiple schemas (such as SQL Server, Oracle, PostgreSQL and DB2 Express) you can filter objects to be retrieved from the database by schema. The available schemas are automatically listed in this panel. Select the checkbox against each schema to include in the import. (You can click on the to select all the schemas, or the to clear all selected checkboxes.) If you suspect that the schema list might have changed since you loaded them, you can refresh the list by clicking on the . |
|
Filter Options |
The ' Options' panel controls what object types and properties are read in from the database schema. Values changed on this screen are saved to the registry so that they are re-applied in the next work session. The available options are briefly described here; select the checkbox against an option to activate it. Tables
Objects
Advanced
Warning: With the 'As Operations' option for Procedures, Functions and Sequences, if objects have been imported under one setting (selected or unselected) and then you change the setting and import further objects, the objects imported under the first setting are removed. |
Database Procedures Database Functions Foreign Keys Indexes Unique Constraints Check Constraints Primary Keys Database Sequences Database Tables Database Views Table Triggers Oracle Packages |
Synchronization |
Select the appropriate radio button to indicate whether the existing Classes are to be updated, or the database objects imported as new objects. If you select the 'Synchronize existing classes' option, also select the appropriate checkboxes to determine whether model comments, column default values and/or Table constraints are to be retained or overwritten with the comments, values and constraints of the imported objects. |
|
Import To |
Select the appropriate radio button to indicate whether to update the Package and currently-open data model diagrams, or just the Package. If no diagrams are open, the 'Package Only' radio button defaults to selected and the options are disabled; if the open diagrams are in the selected Package, you can select either option. |
|
Import |
Click on this button to start the import. The 'Select Database Objects to Import' dialog displays, listing all the database objects found that match the selection criteria. Select the checkbox against each schema (or object type) to automatically select all objects in that group or to import each object individually. Click on the to select all types and objects, or on the to clear all selected checkboxes. When you have selected all the objects to import, click on the to continue the import. |
Notes
Learn more