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 -> Re: Insert into a table within a trigger that raises an exception...

Re: Insert into a table within a trigger that raises an exception...

From: Alain Schartz <schartz_at_mail.com>
Date: 1997/12/04
Message-ID: <3486D52F.7AD0C1E3@mail.com>#1/1

Hi,

> I test for my error conditions, raise a user defined exception and all
> raise_application_error. This stops the insert from occurring (good),
> but rolls back ANY changes that occurred during the execution of the
> trigger (bad) (e.g. a table which logs the invalid insert) which is
> what you'd expect it to do.

Try this:

Do not log into a table but into a file (use the DBMS_FILE package to write into files). AFAIK, COMMITs and ROLLBACKs do not influence the dataflow to and from files, so this should resolve your problem.

Greets,
Al. Received on Thu Dec 04 1997 - 00:00:00 CST

Original text of this message

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