My Oracle Support Banner

USING RAISE_APPLICATION_ERROR ALSO GIVES ERROR ORA-06512 AND POSSIBLY ORA-04088 (Doc ID 1005760.6)

Last updated on MARCH 21, 2025

Applies to:

PL/SQL - Version 9.2.0.8 and later
Information in this document applies to any platform.

Symptoms

Using the RAISE_APPLICATION_ERROR to generate user-defined errors numbers and text does return the user defined errors but also includes additional error codes like ORA-06512 for stored procedures and error ORA-04088 for triggers.

The following illustrates a Stored Procedure that defines a user-defined error.


Sample Output

insert into t1 values (sysdate+1)
*
ERROR at line 1:
ORA-20001: Date entered must not be in the future.
ORA-06512: at "TESTCASE.T1_TRIG", line 4
ORA-04088: error during execution of trigger 'TESTCASE.T1_TRIG'

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.