SQL Job not running but Job History showing in executing status


hi all,

we got server restart on server, later time had checked 1 sql job job not running in sql job history job showing in execution status.

while tried stop manually "stop job" grayed out.

is 1 faced scenario.

thanks,

satish kumar.



thanks, satish kumar. please mark post answered if anser helps resolves issue :)

check using query :-

select job.name, job.job_id, job.originating_server, activity.run_requested_date, datediff(minute, activity.run_requested_date, getdate()) as elapsed, case when activity.last_executed_step_id is null then 'step 1 executing' else 'step ' + convert(varchar(20), last_executed_step_id + 1) + ' executing' end from msdb.dbo.sysjobs_view job join msdb.dbo.sysjobactivity activity on job.job_id = activity.job_id join msdb.dbo.syssessions sess on sess.session_id = activity.session_id join ( select max(agent_start_date) as max_agent_start_date from msdb.dbo.syssessions ) sess_max on sess.agent_start_date = sess_max.max_agent_start_date where run_requested_date is not null and stop_execution_date is null

refer

http://dba.stackexchange.com/questions/83469/job-showing-the-running-sign-but-not-currently-running


please click mark answer if post helped.



SQL Server  >  SQL Server Database Engine



Comments

Popular posts from this blog

Reindexing

Users List

List of charts