SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


SQL agent failed job detailed informtion???


SQL agent failed job detailed informtion???

Author
Message
Lavanyasri
Lavanyasri
SSCrazy
SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)

Group: General Forum Members
Points: 2585 Visits: 966
Hi Team,

We configured different jobs in each sever(full,diff,tlog,dbcc and rebuild \reord,history cleanup jobs).

We are getting alerts when the job is failed is as follows ::

The job failed in the server XXXXXXXX on Nov 14 2012 2:15AM.Please refer the log file for detail information.

We need to search each and evry job to find which job is failed ??.
Is it possible to get a failure alert with the job name , then it is easy to resolve the issue quickly.

I dont have much knowledge on scrpting side ...........

Thanks,
Lavanya
anthony.green
anthony.green
SSC Guru
SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)

Group: General Forum Members
Points: 62690 Visits: 8597
http://www.sqlmag.com/article/tsql3/have-sql-server-email-you-error-messages-generated-by-job-failures

You will need to add a step to the end of every job which is got to by the on failure action of the other steps in the job but this is what we use to get job failure emails.



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
Managing Transaction Logs - Gail Shaw
Troubleshooting SQL Server: A Guide for the Accidental DBA - Jonathan Kehayias and Ted Krueger


Lavanyasri
Lavanyasri
SSCrazy
SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)SSCrazy (2.6K reputation)

Group: General Forum Members
Points: 2585 Visits: 966
Hi Anthony,


Thanks for the quick response ..
I don't want the error message generated by that job failure . I want only the job name with the failure alert ........
anthony.green
anthony.green
SSC Guru
SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)SSC Guru (62K reputation)

Group: General Forum Members
Points: 62690 Visits: 8597
You get an email which contains the below


Job Name = Staging_Circle.MergeResourceToProcessWithResources
--------------------------------------
Step name = Circle.MergeResourceToProcessWithResources
DB Name = Staging_Database
Run Date = Nov 14 2012 11:08AM
Error = Unable to connect to SQL Server 'SQL01\INSTANCE01'. The step failed.

Command = EXEC Circle.MergeResourceToProcessWithResources



You can obivously just go into the procedure and strip out the call to the part which gets the error and command, or use the script as a base point and create your own.



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
Managing Transaction Logs - Gail Shaw
Troubleshooting SQL Server: A Guide for the Accidental DBA - Jonathan Kehayias and Ted Krueger


Bhuvnesh
Bhuvnesh
SSC-Dedicated
SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)SSC-Dedicated (32K reputation)

Group: General Forum Members
Points: 32288 Visits: 4079
Lavanyasri (11/15/2012)
I don't want the error message generated by that job failure . I want only the job name with the failure alert ........
you can use
dbo.sysjobhistory  and dbo.sysjobs 

table to see which job is failing and why

-------Bhuvnesh----------
I work only to learn Sql Server...though my company pays me for getting their stuff done;-)
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