13.26 Exception Declaration
An exception declaration declares the name of a user-defined exception.
You can use the EXCEPTION_INIT
pragma to assign this name to an internally defined exception.
Topics
Syntax
exception_declaration ::=
Semantics
exception_declaration
exception
Name of the exception that you are declaring.
Restriction on exception
You can use exception
only in an EXCEPTION_INIT
pragma, RAISE
statement, RAISE_APPLICATION_ERROR
invocation, or exception handler.
Caution:
Oracle recommends against using a predefined exception name for exception
. For details, see "Redeclared Predefined Exceptions". For a list of predefined exception names, see Table 11-3.
Examples
-
Example 11-5, "Naming Internally Defined Exception"
-
Example 11-9, "Redeclared Predefined Identifier"
-
Example 11-10, "Declaring, Raising, and Handling User-Defined Exception"
Related Topics
In this chapter:
In other chapters: