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

Home -> Community -> Mailing Lists -> Oracle-L -> Mutating table error

Mutating table error

From: Helmut Daiminger <hdaiminger_at_vivonet.com>
Date: Thu, 12 Oct 2000 11:54:31 -0700
Message-Id: <10647.119102@fatcity.com>


Hi!

I got a problem with mutating tables here.

I am updating a row in a table (table_name). There is an after update trigger associated with that table. Within that trigger I try to READ the same table and I get a mutating table error.

CREATE OR REPLACE TRIGGER TBTABS_TRIGGER_UPD_AFTER AFTER UPDATE ON table_name
REFERENCING OLD AS OLD NEW AS NEW
FOR EACH ROW
declare AA Integer;
BEGIN
    AA:=40;
    select count(*) into AA from table_name;     update WHLineType set Amount=AA;
end;

Any idea what I could do to avoid the mutating table error? Received on Thu Oct 12 2000 - 13:54:31 CDT

Original text of this message

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