facebook

Extract DDL not doing anything?

  1. MyEclipse Archived
  2.  > 
  3. Database Tools (DB Explorer, Hibernate, etc.)
Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #249902 Reply

    bobcoss
    Member

    Hi,

    Using XP SP1, ME 4.1.1 GA, Eclipse 3.1, Oracle 9i thin client drivers.

    I’m able to open my database, see the table information, and oracle specific tabs, but when I right click on the table and click on Extract DDL, I get an hour glass briefly, and then nothing happens. Where is the DDL supposed to be extracted to? The help pages implies that it will show up in a new sql editor windows. Extract XML works as expected.

    Also, when I right click on the table and select Generate Table Script, I get a create table script, but it doesn’t include the column sizes. For example for a varchar2 column, it will create the following: “SOMEVARCHARATTRIBUTE” VARCHAR2, but should include the size VARCHAR2(35).

    What am I doing wrong?

    Thank you,

    Bob

    #249908 Reply

    Haris Peco
    Member

    Bob,

    I suggest you that use ‘extract ddl’, because it is enhanced ‘generate table script’ for oracle.If you don’t got output then you haven’t privileges for this object – try log like owner of object or ask your DBA that grant you
    SELECT_CATALOG_ROLE role (with this role you can see ddl for all objects)

    Best regards

    PS
    Question : Have you log in Error log (Windows-Show view- Other – PDE Runtime – Error log view) when you call extract DDL ?

    #249950 Reply

    bobcoss
    Member

    Hi,

    I don’t know what priviledges I have. I can create and alter these tables. If I didn’t have the SELECT_CATALOG_ROLE role, wouldn’t I not be able to see all of the table details in the “Table Info” tab? I can see all of the information there.

    The log file just says: “Error extracting DDL”

    #249952 Reply

    Haris Peco
    Member

    Bob,

    User havent this privileges default.It don’t depend from table browsing (you have browse table, select from table ever), but you can’t see ddl without this role

    if you install database (and haven’t DBA) you can do 2 things :

    1) type DBA user/password in connection profile (for example default SYSTEM user or some user with DBA privilege)

    2) grant this privileges

    log to oracle (from MyEclipse connection proflie like SYSTEM – you can revert after granting) and in sql editor call
    this command

    grant select_catalog_role to <your_username>

    Notes : username and schema are synonyms in oracle
    Error log : you can right click on error (“Error extracting DDL”) and choose ‘Event Details’.You will see
    complete log .I suppose that you will see Oracle error
    ;ORA-31603: object “YOUR_TABLE” of type TABLE not found in schema “YOUR_SCHEMA”

    Best regards

    #249954 Reply

    bobcoss
    Member

    Thank you for the reply.

    Here is the error message I get from oracle when I attempt to extract the ddl:

    java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error
    ORA-31605: the following was returned from LpxXSLResetAllVars in routine kuxslResetParams:
    LPX-1: NULL pointer
    ORA-06512: at “SYS.UTL_XML”, line 0
    ORA-06512: at “SYS.DBMS_METADATA_INT”, line 3712
    ORA-06512: at “SYS.DBMS_METADATA_INT”, line 4544
    ORA-06512: at “SYS.DBMS_METADATA”, line 466
    ORA-06512: at “SYS.DBMS_METADATA”, line 629
    ORA-06512: at “SYS.DBMS_METADATA”, line 1247
    ORA-06512: at line 1

    #249956 Reply

    Haris Peco
    Member

    Bob,

    It isn’t privilege error.It look like oracle internal error.
    Please, answer on a few questions :

    What is your Os , database and jdbc version ?
    Do you got same error for all tables ?
    What is your username in connection profile ?
    Is table which you extract in default schema (like username in profile) ?

    notes : you can see database and jdbc version in connection info view (you will see
    for database 9.x.x.x.x and similar for driver version

    Thanks

    #249957 Reply

    bobcoss
    Member

    Database Product Version: Oacle9i Enterprise Edition Release 9.2.0.7.0 – 64bit Production
    Driver MAjor Version 10:
    Driver Name: Oracle JDBC driver
    Driver Version 10.1.0.2.0
    I don’t know what kind of server the oracle database is on. I suspect it is a solaris box like our weblogic server.

    My windows environment is XP Pro SP1.

    I tried the command in sqlplus (10g instant client drivers) and got the same SYS.DBMS_SYS_ERROR as from ME.

    Bummer….

    #249958 Reply

    Haris Peco
    Member

    Bob,

    I suppose that you have oracle internal error – try recreate plsql packages
    (execute catproc.sql from rdbms/admin or ask experienced DBA)

    You can try recompile package ( user sys in sysdba mode)
    alter package dbms_metadata compile body;
    alter package dbms_metadata compile specification;

    but oracle do it automatic when you call package and it will not help , probably

    try find invalid objects with :

    select owner,object_name,status
    from all_objects
    where status!=’VALID’

    I don’t know how I can help more

    Best regards

Viewing 8 posts - 1 through 8 (of 8 total)
Reply To: Extract DDL not doing anything?

You must be logged in to post in the forum log in