[MSSQL] 2005 이상 LOCK MONITORING
SELECT total_elapsed_time, 'Holder' WaitType, command, blocking_session_id, session_id, status, logical_reads, wait_type, wait_time, last_wait_type, wait_resource, text FROM sys.dm_exec_requests r CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) t WHERE session_id IN (SELECT blocking_session_id FROM sys.dm_exec_requests WHERE blocking_session_id>0) AND blocking_session_id=0 UNION ALL SELECT total_..
더보기