B

Please note that these scripts should be tested before use in a production environment.

B.1 Tables

set wrap off linesize 132 pages 80column tab format a20column col format a15column pos format 990column typ format a10column tbs format a25BREAK ON tab NODUPLICATES SKIP 2 ON NAME NODUPLICATESselect t.table_name "Tab"    ,c.column_name "Col"    ,c.column_id "Pos"    ,c.data_type "Typ"    ,DECODE(c.nullable,'N','NOT NULL',NULL) "Null"    ,t.tablespace_name "Tbs"from user_tables t, user_tab_columns cwhere t.table_name = c.table_nameorder by t.table_name, c.column_id;

B.2 Constraints

set wrap off linesize 132 pages 80column tab format a20column key format a10column cons format a20column col format a10column pos format 990BREAK ON tab NODUPLICATES ...

Get Oracle SQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.