Book a Demo

Author Topic: Generating DDL for Oracle  (Read 4145 times)

HUBERT-JR

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Generating DDL for Oracle
« on: January 17, 2008, 06:07:59 am »
I want to generate a DDL form a Database-Table Design made in EA. I have defined a table which consists of three rows, one of them is ID from type NUMBER. I expect EA to generate a DDL where the statement should be:
CREATE TABLE name-of-table (
   NAME VARCHAR2(100),
   CODE VARCHAR2(10),
   ID NUMBER NOT NULL
);          
but generated was
CREATE TABLE name-of-table (
   NAME VARCHAR2(100),
   CODE VARCHAR2(10),
   ID NUMBER(15,-4840) NOT NULL
);

How can I change the generation for that???

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Generating DDL for Oracle
« Reply #1 on: January 17, 2008, 06:24:57 am »
Don't know.

But I'd take a look at your settings for the column, including the advanced tab and the various index and unique check boxes.

Also, take a look at the settings on the code generation form that comes up - it is so easy to just press Generate - and see if tweaking them has any effect.
No, you can't have it!

HUBERT-JR

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Generating DDL for Oracle
« Reply #2 on: January 17, 2008, 08:24:46 am »
Thanks for your comment. I've already tried, but cannot see any differences. Any other proposals?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Generating DDL for Oracle
« Reply #3 on: January 17, 2008, 08:38:11 am »
Try giving your NUMBER column a specific length (in the EA model). What happens now?
No, you can't have it!

HUBERT-JR

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Generating DDL for Oracle
« Reply #4 on: January 23, 2008, 04:20:57 am »
I tried nearly everything. As results I got something like:
ID NUMBER (8,2)

Thats better than what I had before, but I need to have:
ID NUMBER

Any more ideas?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Generating DDL for Oracle
« Reply #5 on: January 23, 2008, 06:14:51 am »
Sorry, nothing off-hand.

Perhaps someone else has solved this in Oracle. Chime in folks!
No, you can't have it!

hd

  • EA Administrator
  • EA User
  • *****
  • Posts: 312
  • Karma: +0/-0
    • View Profile
Re: Generating DDL for Oracle
« Reply #6 on: January 23, 2008, 01:11:19 pm »
See EA Help Data Modeling | Create Columns.

Half way down the page is a note relating to setting up Oracle NUMBER datatypes.

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Generating DDL for Oracle
« Reply #7 on: January 23, 2008, 02:12:05 pm »
Thanks Henk,

It's been so long since I did an Oracle model I simply forgot. :-[

David
No, you can't have it!