June 2, 2009 at 12:59 am
Hi,
I have configured database mail. I created an operator and I gave 3 dba's email addresses separated by semi colon while creating Operator. Now we are able to receive when a job succeeds.
But I not receiving any email when the jobs fails? what should I do to get an email to the same 3 dba's when the same job fails?
and I need to get some information in the email about the reason for failure.
how can we do this?
how can we send attachments via database mail
thanks
June 2, 2009 at 1:28 am
About the job notification for failed jobs, did you configure the SQL Agent to use the profile? Also very important, after any change to the profile you need to restart SQL Agent.
If you want to send attachments you need to use sp_send_dbmail. Look in BOL for the syntax.
[font="Verdana"]Markus Bohse[/font]
June 11, 2009 at 12:59 am
Yes, I configured sql agent to use profile as below:
sql server agent->properties->alert system->select enable mail profile.
I had configured the database mail as below:
1. I created an operator ABC
2. I gave 3 dba's email addresses separated by semi colon while creating this Operator ABC in the E-mail name
3. In sql server agent jobs ,selected a job->properties->notifications I selected the e-mail and selected the ABC Operator and selected when job succeeds from drop downs.we (e-mail addresses added in the ABC operator) are able to receive when a job succeeds.
Now for the same job, we (e-mail addresses added in the ABC operator) need to get an email, when the job fails. Please tell me how to achieve this task???
June 12, 2009 at 1:22 am
Using SSMS
Right Click on
Management->DatabaseMail
and try to send test mail to ensure you have configured properly.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply