rem ********************************************************************
rem * Author            : Rick Kupcunas
rem * Original          : 10-MAY-95
rem * Description       : Shows the data for a given trigger
rem * Usage             : start show_trg.sql <date>  e.g. 03-MAR-95
rem *                                        <Program Name>
rem *                                        <Max run time (min.)>
rem *
rem ********************************************************************

spool show_trg.rslt;

set pagesize 100;
set linesize 132;
set long 300;
break on "OWNER" on "TRIGGER" on "TBL OWNER";

select substr(owner,1,12)          "OWNER",
       substr(TRIGGER_name,1,25)   "TRIGGER",
       substr(table_owner, 1, 10)  "TBL OWNER",
       trigger_type                "TYPE",
       status                      "STATUS",
       substr(when_clause, 1, 50)  "WHEN....",
       substr(description, 1, 50)  "DESCRIPTION",
       trigger_body                "TRIGGER..."
  from sys.dba_triggers
  where table_name = upper('&&TABLE_NAME');

spool off;
undefine TABLE_NAME;

