Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Debug DDL trigger

RE: Debug DDL trigger

From: David Wendelken <davewendelken_at_earthlink.net>
Date: Tue, 23 Aug 2005 09:35:57 -0400
Message-ID: <009901c5a7e7$980e5fd0$6401a8c0@davidwendelken>

 

> ora_dict_obj_type is a system defined event attribute for DDL triggers,
escentially Oracle-defined variables.  

Duh. :( Should have read it closer! Brain on autopilot read "drop" as "delete".  

Haven't worked with this type of trigger.  

I would suggest turning the when clause into an if statement in the trigger body, and, for debugging purposes, add an else branch that does something you can also trace.
Maybe it doesn't "set" the values until the trigger fires. If nothing else, you can use the else branch to find out what values are in those variables!  

I need this to be a DDL trigger, not a DML trigger, as I want to capture the table and its contents before its dropped. When created, it could be done via CTAS or just CREATE, followed by various DML statements. To capture its final contents I'd be easiest for me to copy it right before it gets dropped. I guess I could generate a materialized view on it when its created, so that all content would be automatically applied to the copy, but I thought this would be easier.    

--
http://www.freelists.org/webpage/oracle-l
Received on Tue Aug 23 2005 - 08:34:12 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US