See who is blocking whom right now
A compact blocking snapshot for production incidents when users report freezes and timeouts.
When the phone rings and “SQL is hung”, start with the blocking chain — not with a reboot.
SELECT
r.session_id,
r.blocking_session_id,
r.wait_type,
r.wait_time,
r.status,
r.command,
DB_NAME(r.database_id) AS database_name,
t.text AS batch_text
FROM sys.dm_exec_requests AS r
CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) AS t
WHERE r.blocking_session_id > 0
OR r.session_id IN (
SELECT blocking_session_id
FROM sys.dm_exec_requests
WHERE blocking_session_id > 0
)
ORDER BY r.blocking_session_id, r.session_id;
Then:
- Find the head blocker
- Identify the transaction (open tran, long report, unexpected lock)
- Decide: wait, kill (last resort), or fix the app pattern
For recurring blocking, fix isolation levels, indexing, and transaction scope — killing SPIDs is not a strategy.
Want this applied to your estate?
We help South African teams implement maintenance and performance improvements properly.