SIGNAL
Valid in: DBProc, TblProc
The SIGNAL statement specifies a condition that will fire an exception handler when it occurs.
The SIGNAL statement has the following format:
SIGNAL signal_value
signal_value
Specifies a condition name or a DBMS error value. The condition name can be a user-defined condition or a predefined condition. The state or error value can be:
SQLSTATE [VALUE] string_literal
Example: SQLSTATE '22012'
DBMSERROR [VALUE] integer_constant | string_literal
The integer value is what would be retrieved by the predefined variable IIERRORNUMBER.
Examples: DBMSERROR 4111 or DBMSERROR 'E_US100F'
Permissions
You must have the CREATE_PROCEDURE privilege.
Related Statements
RESIGNAL
Last modified date: 12/19/2024