Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
AnitaDBA2010
Starting Member
18 Posts |
Posted - 2011-01-28 : 14:51:33
|
Hi All-Could anyone guide me how to change/update the current SQL agent job notification operator ?The current value for the notifications is selected to E-mail domain\abc when job fails and i need to update it domain\xyz i tried executing below command but i received the error msg as belowsp_update_job @job_name ='perfdata' @notify_email_operator_name = 'domain\xyz'Msg 14234, Level 16, State 1, Procedure sp_verify_job, Line 243The specified '@notify_email_operator_name' is invalid (valid values are returned by sp_help_operator).ThanksAnitaAnita |
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
AnitaDBA2010
Starting Member
18 Posts |
Posted - 2011-01-28 : 15:23:46
|
Thank you Tara, you are correct :). i found below query which worked perfectly and i was able to add the operatorUSE [msdb]GOEXEC msdb.dbo.sp_add_operator @name=N'TheNewOne', @enabled=1, ..... @email_address=N'theaddress@the.rest', @category_name=N'[Uncategorized]'GOexecute sp_update_job @job_name=N'yourjob', @notify_email_operator_name=N'TheNewOne';ThanksAnitaquote: Originally posted by tkizer You need to add it as an operator first.Tara KizerMicrosoft MVP for Windows Server System - SQL Serverhttp://weblogs.sqlteam.com/tarad/Subscribe to my blog
Anita |
 |
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
|
|