August 29, 2018 at 1:01 am
When I raise errorraiserror('Test Message', 20, 1) with log
it works fine for severities higher than 18, alert burns and send email to specified operators.
but when severity is smaller than 18 alerts do not burn even when using WITH LOG option.
Can someone specify the syntax for firing alerts where severity < 18.
Thanks
August 29, 2018 at 11:57 am
Are you using:
BEGIN TRY
..
END TRY
BEGIN CATCH
code here to send alert
END CATCH
August 29, 2018 at 3:11 pm
I believe for setting up Alerts by severity, lower level severity errors only generate the alert if they are configured as logged errors. You can see that in the sys.messages tableSELECT * FROM sys.messages m WHERE m.language_id = 1033 AND severity < 19 AND is_event_logged = 1
Some common ones I setup are message_id:
823, 824, 825, 1101, 1105, 6532, 9002, 17053, 18452, 18456, 18470, 18486, 18487, 18488
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply