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

Home -> Community -> Usenet -> c.d.o.server -> trigger help

trigger help

From: Gary Knopp <gknopp_at_ascend.com>
Date: 2000/05/02
Message-ID: <8en5dt$dbc@nntpb.cb.lucent.com>#1/1

I would like to create a generic procedure that writes a tables column name and value to a history table if the value has changed.

Is there anyway to do that without creating an if-endif block for each column value. I don't want to do the following.

         if (:old.col1 <> :new.col1) then

-- insert into history table
end if if (:old.col2 <> :new.col2) then
-- insert into history table
end if

I would like the procedure to be general enough that I don't have to modify it when I add/delete columns from a table that calls the procedure though a trigger.

Thanks Received on Tue May 02 2000 - 00:00:00 CDT

Original text of this message

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