Author Topic: Oracle Reverse Engineer  (Read 10684 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8568
  • Karma: +254/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Oracle Reverse Engineer
« on: May 28, 2018, 02:55:51 pm »
One of our users is trying to reverse engineer an Oracle DB.

We're usually a SQL Server shop, so I haven't done one of these for ages.  Using b1351, he seems to be doing all the right things on the Import from ODBC dialog.  Are there any "gotchas", "secret sauces" that we should be using?

The result is that after asking it to reverse engineer everything, for the tables, we get the table objects, no features or relationships - just empty boxes...

TIA,
Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1297
  • Karma: +119/-10
  • Its the results that count
    • View Profile
Re: Oracle Reverse Engineer
« Reply #1 on: May 28, 2018, 09:44:19 pm »
Done a couple of oracle databases and never been able to get the relationships either. Fortunately the primary keys and foreign keys where named consistently that i wrote a script to create the relationships. Not ideal but i ended up with the desired result.
« Last Edit: May 30, 2018, 06:34:41 am by Sunshine »
Happy to help
:)

Mauricio Moya (Arquesoft)

  • EA User
  • **
  • Posts: 340
  • Karma: +8/-4
  • EA Consulting and development in Spanish
    • View Profile
    • Arquehub Azure Module
Re: Oracle Reverse Engineer
« Reply #2 on: May 29, 2018, 05:00:57 am »
Are you using legacy reverse engineering? Have you tried Database Builder?

hd

  • EA Administrator
  • EA User
  • *****
  • Posts: 312
  • Karma: +0/-0
    • View Profile
Re: Oracle Reverse Engineer
« Reply #3 on: May 29, 2018, 08:20:48 am »
Make sure the ODBC driver is the Oracle driver and not the "Microsoft ODBC for Oracle" driver.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8568
  • Karma: +254/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Oracle Reverse Engineer
« Reply #4 on: May 29, 2018, 09:45:08 am »
Are you using legacy reverse engineering? Have you tried Database Builder?
Yes (I think so), I'll give it a go!

Paolo
[EDIT: I tried it, but it seems to me that the import DB Schema is the SAME dialog as the non-Database Builder route.  I tried an SQL Server DB (as my user isn't in yet) and both routes worked fine.]
« Last Edit: May 29, 2018, 11:17:11 am by Paolo F Cantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8568
  • Karma: +254/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Oracle Reverse Engineer
« Reply #5 on: May 29, 2018, 09:46:13 am »
Make sure the ODBC driver is the Oracle driver and not the "Microsoft ODBC for Oracle" driver.
Will do, when I get in to work.

I should get both the columns AND the FK relationship, yes?

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Glassboy

  • EA Practitioner
  • ***
  • Posts: 1367
  • Karma: +112/-75
    • View Profile
Re: Oracle Reverse Engineer
« Reply #6 on: May 29, 2018, 01:17:16 pm »
Make sure the ODBC driver is the Oracle driver and not the "Microsoft ODBC for Oracle" driver.
Will do, when I get in to work.

I should get both the columns AND the FK relationship, yes?

Paolo

It's been a few years since I reverse engineered an Oracle DB but I remember getting everything.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8568
  • Karma: +254/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Oracle Reverse Engineer
« Reply #7 on: May 29, 2018, 04:39:25 pm »
A combination of V14 and the DB Builder (we were using the Oracle ODBC drive - 11.0.2.1) did it.

We imported 2355 tables, 159 views etc...   However, we got a Resources Exceeded message and thought it might have damaged the FK Constraint import.  But it seems that this product hasn't got any FK Constraints!

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13136
  • Karma: +547/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Oracle Reverse Engineer
« Reply #8 on: May 29, 2018, 04:58:27 pm »
But it seems that this product hasn't got any FK Constraints!

Who in his right mind would design a database without FK constraints!  :o
Ohh, um, ... nevermind...  :-X

Geert

Richard Freggi

  • EA User
  • **
  • Posts: 483
  • Karma: +18/-7
    • View Profile
Re: Oracle Reverse Engineer
« Reply #9 on: May 29, 2018, 10:10:38 pm »
I'm not an Oracle expert but any RDBMS should spit out the schema DDL code as a text file on request.  Then just run the DDL in EA to recreate the schema as a physical data model?

qwerty

  • EA Guru
  • *****
  • Posts: 13573
  • Karma: +395/-301
  • I'm no guru at all
    • View Profile
Re: Oracle Reverse Engineer
« Reply #10 on: May 30, 2018, 12:00:01 am »
Why do it the simple way if you can go through a variety of ODBC and native drivers instead?

q.

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1297
  • Karma: +119/-10
  • Its the results that count
    • View Profile
Re: Oracle Reverse Engineer
« Reply #11 on: May 30, 2018, 06:48:45 am »
I'm not an Oracle expert but any RDBMS should spit out the schema DDL code as a text file on request.  Then just run the DDL in EA to recreate the schema as a physical data model?
Interesting I didn't know you could run DDL in EA to recreate the schema. I've search the help and can't find anything on that particular feature. Care to share a reference on how to access it?
Happy to help
:)

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1297
  • Karma: +119/-10
  • Its the results that count
    • View Profile
Re: Oracle Reverse Engineer
« Reply #12 on: May 30, 2018, 06:50:48 am »
Why do it the simple way if you can go through a variety of ODBC and native drivers instead?

q.
Probably because the help tells you to use ODBC drivers. Haven't found out how to run DDL in EA yet though. Still searching in the online help for that feature.
https://www.sparxsystems.com/downloads/resources/booklets/uml_code_engineering.pdf
Happy to help
:)

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8038
  • Karma: +118/-20
    • View Profile
Re: Oracle Reverse Engineer
« Reply #13 on: May 30, 2018, 08:56:23 am »
EA can't reverse engineer a DB schema from a sql file.

qwerty

  • EA Guru
  • *****
  • Posts: 13573
  • Karma: +395/-301
  • I'm no guru at all
    • View Profile
Re: Oracle Reverse Engineer
« Reply #14 on: May 30, 2018, 05:27:29 pm »
Yes, I know that EA can't RE a DDL. Unfortunately there's no emphasis for irony/sarcasm in texts.

q.