Script to Monitor the Running Job Status

Think of environment where multiple jobs are running at the same time and you want to monitor the current status of each job. One option is to use the job activity monitor.


And another way is you can use the below system stored procedures by running it against the MSDB database.


exec msdb..sp_get_composite_job_info

exec msdb.dbo.sp_help_job
@execution_status = 1


You can check the job execution status parameter values as below.

0 = Not idle or suspended

1 = Executing

2 = Waiting For Thread

3 = Between Retries

4 = Idle

5 = Suspended

6 = Waiting For Step To Finish

7 = Performing Completion Actions



Thanks for the comment, will get back to you soon... Jugal Shah

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s