17.07.2015 Views

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9 – Honeycombing a DatabaseCreating an Operator for NotificationThe first step in creating a SQL Server alert is to create an Operator. AnOperator is the person, or people, who will receive an alert when one is raised.We create an operator by executing the sp_add_operator system storedprocedure in Management Studio. The following is an example of the syntax ofthis system stored procedure:sp_add_operator [Operator Name],[Enabled],[Email Address],[Pager Address],[Weekday Pager Start],[Weekday Pager End],[Saturday Pager Start],[Saturday Pager End],[Sunday Pager Start],[Sunday Pager End],[Available Pager Days],[Netsend Address],[Category]This system stored procedure's arguments are as follows:• Operator Name – the textual reference to the Operator.• Enabled – indicates whether the Operator can receive notifications.• Email Address – the e-mail address to which notifications are sentfor this Operator. This argument is only necessary when notifyingthrough e-mail.• Pager Address – all pager notifications are sent through the e-mailsystem. The value of this argument will need to be the e-mail accountof the pager that will receive notifications. This argument is onlynecessary when notifying through a pager.• Weekday Pager Start/End – the time of day during the weekdaythat notifications can be received. The value must be in the format ofHHMMSS (Hour, Minute, Second). 0 indicates midnight. Despite thisargument having the word "Pager" in it, it applies to e-mailnotifications as well. This argument is only necessary when theOperator is active on weekdays.• Saturday Pager Start/End – the time of day on Saturday thatnotifications can be received. This argument is only necessary whenthe Operator is active on Saturdays.• Sunday Pager Start/End – the time of day on Sunday thatnotifications can be received. This argument is only necessary whenthe Operator is active on Sundays.• Available Pager Days – this indicates the days on which theOperator is available to receive notifications. This value ranges from 0194

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!