Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

where can I find the current job status in the msdb tables?

Status
Not open for further replies.

aolb

Programmer
Apr 16, 2002
180
GB
I want to write a query that returns if a specified job is currently running. I expect to find this data in the msdb.dbo.sysjobs or msdb.dbo.sysjobhistory tables but nothing jumps out as the field I want.

Can someone tell me what field and table I need to return the current job status?

Thanks
 
Hey aolb,

My turn to help you (possibly)! Have a look at this link - it is for long running jobs set to check if something has been running for 6 hours or more but can be adapted to see exactly what is running and how long it has been running.

Long Running Job

Cheers,

M.
 
thanks mutley1... not straight forward as the is come converting from hex to char to do in the solution. will give it a go
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top