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

Home -> Community -> Usenet -> c.d.o.tools -> significance of user_trigger_cols.column_list

significance of user_trigger_cols.column_list

From: Eric Givler <egivler_at_flash.net>
Date: 2000/08/11
Message-ID: <YIWk5.178$ic.17996@news.flash.net>#1/1

    What's the significance of this column?

    I had a script that I used to export triggers for a table and it showed:

create or replace
trigger RESERVATIONS_BR_IU
before INSERT OR UPDATE OF UPDATED_BY_EID, UPDATED_DATE on RESERVATIONS
FOR EACH ROW
begin

   declare

      UserEID    number := StandardTasks.GetUserEID( USER );
      TodaysDate date   := SYSDATE;
   begin
      if :NEW.UPDATED_DATE is null
         or trunc( :NEW.UPDATED_DATE ) != trunc( TodaysDate ) then

:NEW.UPDATED_DATE := TodaysDate;
end if; if :NEW.UPDATED_BY_EID is null then
:NEW.UPDATED_BY_EID := UserEID;
end if; exception when OTHERS then null;

    end;
end;

However, when I looked into USER_TRIGGER_COLS, the column_list for both these fields was "NO" and not
"YES". The trigger appeared to fire for updates to columns OTHER Than the ones in the list, so I recreated the
above with some DBMS_OUTPUT statements. When I ran the trigger, it looked like it didn't fire at all (I had serveroutput on in SQL*Plus). This time, when I viewed user_trigger_cols, the column_list showed: "YES"

So, I take it my script to create the triggers wasn't exactly correct, and what's the signifance of those two columns first showing up in user_trigger_cols if the trigger wasn't using them when it fired? Received on Fri Aug 11 2000 - 00:00:00 CDT

Original text of this message

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