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 -> catching raise_application_error from within a trigger with ADO

catching raise_application_error from within a trigger with ADO

From: news <heiko.folkerts_at_david-bs.de>
Date: Thu, 13 Nov 2003 14:19:58 +0100
Message-ID: <bp03gi$761$1@news.dtag.de>


Hi,
I am using the latest oracle oledb Provider (9.2.0.2) to access a database (9.2.0.1) on which triggers whatch the insertion and update of records. My client is written in visual c++ 6.0 using ADO 2.7. The Triggers on the database call raise_application_error to rollback the unauthorized operation. Everything goes well except that the oracle oledb provider throws the exception (COleDispatch) with the correct error code and message against the winproc part of my client application instead of throwing it against the call to ADO. The effect is that when the call fails due to failing of the trigger the execution of the client is directly continued in the CWinapp::ProcessWinprocException. The application ends after the exception even when it is caught.
I am unable to catch the exception at the call to ADO. Has anyone discovered this problem? Has anyone any suggestion how to go arround this behaviour? The Problem doesn't occur when the Microsoft Provider for oracle is used, but there are other reasons why we can't use that provider. Many thanks
Heiko Received on Thu Nov 13 2003 - 07:19:58 CST

Original text of this message

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