FirebirdSQL logo
 SEQUENCE (GENERATOR)COLLATION 

Who Can Alter an Exception

The ALTER EXCEPTION statement can be executed by:

  • Administrators

  • The owner of the exception

  • Users with the ALTER ANY EXCEPTION privilege

ALTER EXCEPTION Examples

Changing the default message for the exception E_LARGE_VALUE
ALTER EXCEPTION E_LARGE_VALUE
  'The value exceeds the prescribed limit of 32,765 bytes';

CREATE OR ALTER EXCEPTION

Creates a custom exception if it doesn’t exist, or alters a custom exception

Available in

DSQL

Syntax
CREATE OR ALTER EXCEPTION exception_name '<message>'

!! See syntax of CREATE EXCEPTION for further rules !!

The statement CREATE OR ALTER EXCEPTION is used to create the specified exception if it does not exist, or to modify the text of the error message returned from it if it exists already.If an existing exception is altered by this statement, any existing dependencies will remain intact.

CREATE OR ALTER EXCEPTION Example

Changing the message for the exception E_LARGE_VALUE
CREATE OR ALTER EXCEPTION E_LARGE_VALUE
  'The value is higher than the permitted range 0 to 32,765';