home‎ > ‎table‎ > ‎


Use this command to get the DDL for a table. Output is based on the dbschema utility. Create a template to specify the output format.


infx table func=ddl db tab
     display table ddl
         db - select database
         tab - the name of the table or enter owner.table


demo1@bobii:/home/informix>infx table func=ddl db=monitor_jgh1 tab=objectdailydetail templ=infx-test-tabddl

{ TABLE "informix".objectdailydetail row size = 385 number of columns = 27 index size = 477 }
create table "informix".objectdailydetail
    mon_date datetime year to day,
    sub char(5)
        default 'all' not null ,
    dbname char(36),
    tabname char(36),
    object char(36),
    space char(36),
    alloc_kb decimal(20,0),
    used_kb decimal(20,0),
    rows decimal(20,0),
    extents decimal(20,0),
    alloc_delta decimal(20,0),
    used_delta decimal(20,0),
    rows_delta decimal(20,0),
    delta_days decimal(20,0),
    bufreads decimal(20,0),
    bufwrites decimal(20,0),
    pagereads decimal(20,0),
    pagewrites decimal(20,0),
    lockreqs decimal(20,0),
    lockwts decimal(20,0),
    deadlks decimal(20,0),
    lktouts decimal(20,0),
    isreads decimal(20,0),
    iswrites decimal(20,0),
    isrewrites decimal(20,0),
    isdeletes decimal(20,0),
    seqscans decimal(20,0)
  ) extent size 6998 next size 2500 lock mode page;

revoke all on "informix".objectdailydetail from "public" as "informix";

create index "informix".ix1_odd on "informix".objectdailydetail
    (dbname,tabname,mon_date) using btree  in idx01;
create index "informix".ix2_odd on "informix".objectdailydetail
    (mon_date,dbname,tabname) using btree  in idx01;
create index "informix".ix3_odd on "informix".objectdailydetail
    (dbname,tabname,object,space,mon_date) using btree  in idx01;

create unique index "informix".px_odd on "informix".objectdailydetail
    (mon_date,sub,dbname,tabname,object,space) using btree  in