The TDSNDMSG function uses the following parameters to return error information:
MESSAGE_TYPE – indicates whether the message is an informational or an error message.
MESSAGE_NUMBER – the number that identifies the message.
SEVERITY – the severity level of the error. These levels correspond to the following SQL Server severity levels:
01 – 10 Status information 11 – 16 Client application errors 17 – 18 Nonfatal software or hardware errors 19 – 24 Fatal system errors
ERROR_STATE – provides additional information about the context of the error for Sybase Technical Support.
LINE_ID – identifies the line number or area of the client program where the error was detected.
TRANSACTION_NAME – the name of the currently executing transaction.
TRANSACTION_NAME_LENGTH – the length of the TRANSACTION_NAME parameter.
MESSAGE_TEXT – the text of the message.
MESSAGE_LENGTH – the length of the MESSAGE_TEXT parameter.