Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
Notification Services
»
Administration
»
Database Mail Notification
Database Mail Notification
Rate Topic
Display Mode
Topic Options
Author
Message
sairam6819
sairam6819
Posted Monday, April 16, 2012 6:20 PM
Forum Newbie
Group: General Forum Members
Last Login: Tuesday, April 24, 2012 3:16 PM
Points: 9,
Visits: 36
Hello ,
Can you suggest me how to Receive a mail notification, not as soon as job completes but at a particular time after the job completion. In the job setup window, I just have an option in notifications as ' when job succeeds'. I want to get notified in the morning after job succeeds (job runs at night). May be I was thinking that I can use jobhistory tables (job_status column) and write a script such that if status is success, notify operator at particular time. Any suggestions would be appreciated.
Post #1284614
peterdru401
peterdru401
Posted Thursday, January 03, 2013 5:49 AM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 16, 2013 8:34 AM
Points: 23,
Visits: 128
You can set some alert through an utility like after the successful completion of job you will receive a mail
Use some monitoring software like this
http://www.windowseventlogmonitor.com/
Post #1402313
anthony.green
anthony.green
Posted Thursday, January 03, 2013 5:54 AM
SSCertifiable
Group: General Forum Members
Last Login: Friday, April 12, 2013 3:51 AM
Points: 5,075,
Visits: 4,831
Add a step into the job which uses WAITFOR TIME command to delay the sending of the mail. Then execute a msdb.dbo.sp_send_dbmail command with the mail you want to send.
I would do two, one for success one for failure, then set the main job step to go to the right mail step depending on its outcome.
So
Step1 - Run my procedure, on success go to step2, on failure go to step3
Step2 - WAITFOR TIME '07:30' send success mail, on success quit reporting success, on failure quit reporting failure
Step3 - WAITFOR TIME '07:30' send failure email, on success quit reporting failure, on failure quit reporting failure
Want an answer fast? Try here
How to post data/code for the best help - Jeff Moden
Need a string splitter, try this - Jeff Moden
How to post performance problems - Gail Shaw
CrossTabs-Part1
&
Part2 - Jeff Moden
SQL Server Backup, Integrity Check, and Index and Statistics Maintenance - Ola Hallengren
Managing Transaction Logs - Gail Shaw
Troubleshooting SQL Server: A Guide for the Accidental DBA - Jonathan Kehayias and Ted Krueger
Post #1402314
« Prev Topic
|
Next Topic »
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.