Read more: http://www.blogsmonetize.com/2010/10/how-to-use-syntax-highlighter-3083-in.html#ixzz1DHzvEgBA

Monday, June 9, 2008

Executing a Job from Query Analyser

Here am going to explain how do we run a job from query analyser. This feature would be helpful at the time of your testing phase of a job. Once we confirmed the desired functionality, we would be able to go ahead and schedule the job.



--Use msdb, the proc exists in it
use msdb;
Go
exec dbo.sp_start_job ''

--Waiting the job to be executed
Waitfor Delay '000:00:15'

No comments: