Loading sub-menu...

Reverse Engineer a Remote DB2 Database in RSA 7

Today I learned how to reverse engineer a remote DB2 database to generate a database diagram using Rational Software Architect (RSA) 7. Here's the skinny:

Establish a connection to the remote DB2 database

  • In RSA, switch to the Data perspective; select Window -> Open Perspective - Data.
  • In the Database Explorer view, right-click on the Connections node and select New Connection...
  • In the New Connection dialog, make appropriate entries for your remote datasource. For example:
    • Select a database manager: DB2 UDB v8.2
    • JDBC Driver: IBM DB2 Universal
    • Database: FRAMEWK9 (the name of your remote DB)
    • Host: usnencx206.ndc.nna (server host name or I.P.)
    • Port number: 50000 (usual default port for DB2)
    • Use client authentication: no (not checked)
    • User ID: ...
    • Password: ..
  • Click Test Connection; before next step, you want to get "Connection to DB2 UDB is successful."
  • Click Next
  • Unselect 'Disable Filter'
  • Enter the Expression 'Starts with the characters' -> "WPSDB" or whatever schema holds the tables you are interested in. If you aren't sure, leave Disable Filter checked. You can always go back and edit the connection to filter out unwanted schema prefixes after you find what you are looking for. The reason why you want to filter is to reduce system schemas and such that are irrelevant (they usually start with the characters SYS).
  • Click Finish

Reverse engineer to create a database diagram

Now that we have a connection to a remote database, we can use Rational to reverse engineer it into a diagram.

  • In the Database Explorer view, expand your database connection node to the diagrams level. For example: FRAMEWK9 -> Schemas -> WPSDB -> Diagrams
  • Right click the diagram node under Diagrams (mine is WPSDB) and select Open Overview Diagram.
  • In the Overview Diagram Selection dialog, check all elements from the schema that you want in the diagram and click OK. A diagram will be generated.
  • In the Properties view,configure compartment display options. For example, check show-key and show non-key for more detail. Choose other options as desired.
  • Finally, you can drag items around in the diagram to create a better layout than RSA gives automatically. You can also right-click in the diagram and select Arrange All to auto-arrange the view (but it is still not as good as doing it manually).

That's it!



Labels

db2 db2 Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.