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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Problem with triggers

Re: Problem with triggers

From: Philippe <parnaud_at_yahoo.com>
Date: Tue, 4 May 1999 14:06:53 +0200
Message-ID: <7gmnvi$q20$1@concorde.ctp.com>


In the trigger assign all :new.values to :old.values and don't raise an error

HTH
Philippe

Olaf Hansen wrote in message <372ED9DB.960_at_is.informatik.uni-kiel.de>...
>Hi,
>
>I'm working with Oracle7.x and WindowsNT.
>
>Now I have the following problem with triggers :
>
>The goal:
>When updating a row in table X a trigger (before update) is called. If a
>defined condition is met I want the trigger to insert a row in table Y
>and refuse the update for table X (for example by raising an application
>error).
>
>My problem now is that raising an application error (for refusing the
>update on table X) implies a complete rollback of the transaction
>(including rollback the insert on table Y).
>
>
>Do anyone know a solution for this ?
>
>It must be guarantied that noone can change table X between checking the
>defined condition and doing the update (or no update, depending on the
>condition) of table X.
>
>
> Thanks, Olaf
>
>
>
>Olaf Hansen
>
>Student of Computer Science
>at University of Kiel, Germany
>
>oha_at_is.informatik.uni-kiel.de
Received on Tue May 04 1999 - 07:06:53 CDT

Original text of this message

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