Follow sqlserver-dba.com

Subscribe to RSS feed  Follow @jackvamvas - Twitter

*Use the Comments section for questions

SQLServer-DBA.com Links

Dba_db2_button

dba-ninja.com

SQL Server DBA Jobs

SQL Blocking script

24 April,2007 by Tom Collins

List SQL processes which are blocked. List which  SQL processes are blocking other processes.

 

/******************************************************************
-- Description  :processes which are blocked, which processes are blocking other processes
-- Last Modified:19/03/2007
******************************************************************/
SELECT * FROM dbo.sysprocesses WHERE blocked <> 0;
SELECT * FROM dbo.sysprocesses WHERE spid IN (SELECT blocked FROM dbo.sysprocesses where blocked <> 0);

How to monitor Blocked Processes with SQL Alert and email sp_whoisActive report

Read More

sys.sysprocesses and permissions

Cached blocking history with sys.dm_db_index_operational_stats

SQL Server – Deleting Distributed Orphaned Transactions

 


Author: Tom Collins (http://www.sqlserver-dba.com)


Share:

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment on SQL Blocking script


sqlserver-dba.com | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact|Copyright & Disclaimer