Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
Log in  ::  Register  ::  Not logged in
Home       Members    Calendar    Who's On

Add to briefcase

Configuring a job to check for any running jobs Expand / Collapse
Posted Wednesday, April 2, 2014 10:38 AM


Group: General Forum Members
Last Login: Monday, February 9, 2015 5:58 AM
Points: 175, Visits: 916
Hi all,

We will soon be migrating to SS2K8, and before we cutover we need take our DB's offline/into Single User mode. In order to ensure consistency we need to ensure that process waits until any running have finished.

I have prepped a small script for the task, but would appreciate any advice on how to go further...

Select *
From sysjobhistory
Where run_status <>1

WAITFOR DELAY '00:00:10'

Select *
From sysjobhistory
Where run_status <>1


Post #1557602
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse