Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 12963

Capture duration time and use it in customized the SQL Server Job System Message

$
0
0

Hi there

I am trying to capture the job duration time and put it on the customized Job email subject.

This is the original message from SQL server, the Bold one is what I am trying to capture.

JOB RUN:            'Hello' was run on 7/30/2014 at 8:05:00 AM

DURATION:        0 hours, 0 minutes, 2 seconds

STATUS:              Succeeded

MESSAGES:        The job succeeded. The Job was invoked by Schedule 27 (Job 2).  The last step to run was step 1 (Test).

Is there anyway to do that? I have tried to pull it from jobhistory and I did't have any luck.

Cheers,

Matt


Viewing all articles
Browse latest Browse all 12963

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>