describe multiple tables.sql
 — tab_dc.sql
 — MDW – Allows repeat running, having started own spooling
 SET PAUSE off
 SET PAUSE ‘Any Key…>’
 SET PAGES 32
 break on tab_own skip 1 on tab_name skip 1
 SELECT
substr(OWNER,1,10)Â Â Â Â Â Â Â Â Â Â Tab_Own
,substr(TABLE_NAME,1,23)Â Â Â Tab_Name
,substr(COLUMN_NAME,1,28)Â Â Col_Name
,decode(NULLABLE,’Y’,’N’,’Y’)Â Â Â Â Â Â Â Mand
,substr(data_type||decode(data_type
      ,’NUMBER’,'(‘
       ||decode(to_char(data_precision)
               ,null,’38’
               ,    to_char(data_precision)||
                     decode(data_scale,null,”
                                     ,     ‘,’||data_scale)
                )
                   ||’)’
      ,’DATE’,null
      ,’LONG’,null
      ,’LONG RAW’,null
      ,'(‘||Substr(DATA_LENGTH,1,5)||’)’
      ) ,1,12) col_def
FROM ALL_TAB_COLUMNS
where table_name like upper (nvl(‘&TAB_NAME’,’WHOOPS’)) –||’%’)
order by 1,2,column_id,3,4
/
— EOF
Discussion ¬