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 -> Re: trigger question

Re: trigger question

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: 2000/08/01
Message-ID: <965153956.20935.7.pluto.d4ee154e@news.demon.nl>#1/1

Without seeing the actual code:
this occurs when you are selecting from a table in a transaction. Either you shouldn't use select (do you *really* need to do that) or you should

- create a pl/sql table in a before ... statement trigger
- buffer the primary key in the pl/sql table in a before row trigger
- process the table in an after statement trigger
refer to http://osi.oracle.com/~tkyte for further details.

Hth,

Sybrand Bakker, Oracle DBA

"luio" <lctNOlcSPAM_at_hotmail.com.invalid> wrote in message news:09003a9e.e7b67c8f_at_usw-ex0104-028.remarq.com...
> no matter I set it as before or after delete, it will report
> 04901 error.
> how can I void it?
> the only condition I used is like
> delete from table1 where table1.column1 = :old.cl1;
> ????
>
> ORA-04091 table string.string is mutating, trigger/function may
> not see it
> Cause: A trigger (or a user defined PL/SQL function that is
> referenced in this statement) attempted to look at (or modify) a
> table that was in the middle of being modified by the statement
> which fired it.
>
> Action: Rewrite the trigger (or function) so it does not read
> that table.
>
> thank you
>
>
>
>
> -----------------------------------------------------------
>
> Got questions? Get answers over the phone at Keen.com.
> Up to 100 minutes free!
> http://www.keen.com
>
Received on Tue Aug 01 2000 - 00:00:00 CDT

Original text of this message

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