ASA Database Administration Guide
Database Options
Alphabetical list of options
Controls behavior following a RAISERROR statement.
ON, OFF
OFF for databases created with Version 5.x.
ON for databases created with Version 6 or later.
ON_TSQL_ERROR option [compatibility]
The RAISERROR statement is used within procedures and triggers to generate an error. When this option is set to OFF, the execution of the procedure or trigger is stopped whenever the RAISERROR statement is encountered.
If you set the CONTINUE_AFTER_RAISERROR option to ON, the RAISERROR statement no longer signals an execution-ending error. Instead, the RAISERROR status code and message are stored and the most recent RAISERROR is returned when the procedure completes. If the procedure that caused the RAISERROR was called from another procedure, the RAISERROR is not returned until the outermost calling procedure terminates.
Intermediate RAISERROR statuses and codes are lost after the procedure terminates. If, at return time, an error occurs along with the RAISERROR, then the information for the new error is returned and the RAISERROR information is lost. The application can query intermediate RAISERROR statuses by examining the @@error global variable at different execution points.
The setting of the CONTINUE_AFTER_RAISERROR option is used to control behavior following a RAISERROR statement only if the ON_TSQL_ERROR option is set to CONDITIONAL (the default). If you set the ON_TSQL_ERROR option to STOP or CONTINUE, the ON_TSQL_ERROR setting takes precedence over the CONTINUE_AFTER_RAISERROR setting.