Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


SQL 2005 ALERTS Not Working for non-logged events


SQL 2005 ALERTS Not Working for non-logged events

Author
Message
ganci.mark
ganci.mark
Right there with Babe
Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)

Group: General Forum Members
Points: 731 Visits: 545
SQL 2005 Enterprise X64 SP4
ALERTS: SQL SERVER EVENT ALERT ---->Severity

Has anyone noticed that the Alerts only seem to trigger when the "Event" is logged to the Errorlog?
Anything that does not end up in the log does not seem to produce an alert response or update the alert history.
I can recreate this easily:
RAISERROR('Error test, 16, 1) WITH LOG; -- This triggers alert successfully
RAISERROR('Error test, 16, 1); -- This will not

My problem is I would like non-user defined errors to trigger alerts.
For example: Msg 8134, Level 16, State 1, Line 1

Is this a known bug? Are there configuration settings to change what errors are recorded in the log?
Can I send all Severity 16 to the log? (without raiserror)

Thanks for your help.
Mark G.
Orlando Colamatteo
Orlando Colamatteo
SSCrazy Eights
SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)

Group: General Forum Members
Points: 8235 Visits: 14368
These are the English messages that get logged automatically.

SELECT  *
FROM sys.messages
WHERE language_id = 1033
AND (
is_event_logged = 1
OR severity >= 19
)
ORDER BY message_id;



If you want to start logging error 8134, or any message that is not logged by default, you can use this:

DECLARE @message_id INT = 8134;

EXEC sys.sp_altermessage
@message_id = @message_id,
@parameter = 'WITH_LOG',
@parameter_value = 'TRUE';



__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato
ganci.mark
ganci.mark
Right there with Babe
Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)Right there with Babe (731 reputation)

Group: General Forum Members
Points: 731 Visits: 545
OPC, exactly what I was looking for.
Thank you very much!


Mark G.
Orlando Colamatteo
Orlando Colamatteo
SSCrazy Eights
SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)SSCrazy Eights (8.2K reputation)

Group: General Forum Members
Points: 8235 Visits: 14368
You're welcome. Thanks for the feedback.

__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search