Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 How to kill a job?

Author  Topic 

Sun Foster
Aged Yak Warrior

515 Posts

Posted - 2006-10-13 : 03:59:25
How to kill a job on the half way? For example, I add index in a table in which there is a huge data. After click save, I change mind and want to kill this job.

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2006-10-13 : 04:20:46
Try msdb..sp_stop_job

Harsh Athalye
India.
"Nothing is Impossible"
Go to Top of Page

Sun Foster
Aged Yak Warrior

515 Posts

Posted - 2006-10-13 : 04:28:37
EXEC sp_stop_job @job_name = 'Archive Tables', will it stop all jobs?
How to stop only one job, if there are job running?
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2006-10-13 : 04:30:34
enterprise manager>management>sql server agent> jobs>right click job to stop, stop job

--------------------
keeping it simple...
Go to Top of Page

Sun Foster
Aged Yak Warrior

515 Posts

Posted - 2006-10-13 : 06:34:18
Save index is not under sql server agent job
Go to Top of Page

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2006-10-13 : 06:46:50
quote:
Originally posted by Sun Foster

Save index is not under sql server agent job



Then why are you asking how to kill a job?


CODO ERGO SUM
Go to Top of Page

Sun Foster
Aged Yak Warrior

515 Posts

Posted - 2006-10-13 : 07:06:04
When save after adding new index, hourglass last for ever!
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2006-10-13 : 08:44:17
it's not a job you want to kill, it's an spid

run sp_who, check the spid of the transaction you ran and issue a KILL spid

--------------------
keeping it simple...
Go to Top of Page
   

- Advertisement -