-- Kill Process ID 84
KILL 84

Once we KILL SPID in SQL Server, it becomes an uncompleted transaction. SQL Server must undo all changes performed by the uncompleted transaction and database objects should be returned to the original state before these transactions. Due to this reason, you can see the status of SPID as KILLED\ROLLBACK once the rollback is in progress. Rollback might take less time in most of the case; however, it entirely depends upon the changes it needs to rollback.

-- Returns the estimate return time for the rollback in seconds.
-- DOES NOT KILL the process.
KILL 84 with STATUSONLY

The KILL command with STATUSONLY does not kill any process. It returns the estimated return time for the rollback in seconds.

Sources:

Last modified: December 23, 2019

Author

Comments

Write a Reply or Comment