Applies To: SQL Server 2014, SQL Server 2016 Preview
Generates an error message and initiates error processing for the session. RAISERROR can either reference a user-defined message stored in the sys.messages catalog view or build a message dynamically.
The message is returned as a server error message to the calling application or to an associated CATCH block of a
construct. New applications should use THROW instead.
Applies to: SQL Server (SQL Server 2008 through current version), Azure SQL Database, Azure SQL Data Warehouse Public Preview.