-- Find what's blocking the delete
SELECT
    session_id,
    blocking_session_id,
    wait_type,
    wait_time,
    last_wait_type,
    command,
    status
FROM sys.dm_exec_requests
WHERE blocking_session_id <> 0;

-- See all active sessions on this database
SELECT
    s.session_id,
    s.login_name,
    s.host_name,
    s.program_name,
    s.status,
    r.command,
    r.blocking_session_id
FROM sys.dm_exec_sessions s
LEFT JOIN sys.dm_exec_requests r ON s.session_id = r.session_id
WHERE s.database_id = DB_ID('PowderCoatingDb');

-- To kill a specific session (replace XX with session_id):
-- KILL XX;
