Mutating tables
From: Richard Long <rlong01_at_dallas.net>
Date: 1996/01/12
Message-ID: <4d51vg$br8_at_dns.plano.net>#1/1
end;
/
Date: 1996/01/12
Message-ID: <4d51vg$br8_at_dns.plano.net>#1/1
I'm moving a system from sybase to oracle and am having some problems
with triggers. I've followed the doc to set-up a trigger to set a key
to -1 everytime the table is inserted. It no longer mutates but the
update from the trigger does not take place. What is a good way to
make this happen. Trigger follows:
create OR REPLACE trigger tI_attachee
after insert on attachee FOR EACH ROW DECLARE mutating_table EXCEPTION; PRAGMA EXCEPTION_INIT (mutating_table, -4091);begin
update attachee
set acu_stdld_key_i = -1 where attachee.xtern_co_id_c = :old.xtern_co_id_c and attachee.attachee_cd_id_c = :old.attachee_cd_id_c; EXCEPTION WHEN mutating_table THEN null;
end;
/
Thanks Received on Fri Jan 12 1996 - 00:00:00 CET