Advertisement
Guest User

Untitled

a guest
May 25th, 2016
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. SELECT
  2. t1.resource_type,
  3. t1.resource_database_id,
  4. t1.resource_associated_entity_id,
  5. t1.request_mode,
  6. t1.request_session_id,
  7. t2.blocking_session_id,
  8. o1.name 'object name',
  9. o1.type_desc 'object descr',
  10. p1.partition_id 'partition id',
  11. p1.rows 'partition/page rows',
  12. a1.type_desc 'index descr',
  13. a1.container_id 'index/page container_id'
  14. FROM sys.dm_tran_locks as t1
  15. INNER JOIN sys.dm_os_waiting_tasks as t2
  16. ON t1.lock_owner_address = t2.resource_address
  17. LEFT OUTER JOIN sys.objects o1 on o1.object_id = t1.resource_associated_entity_id
  18. LEFT OUTER JOIN sys.partitions p1 on p1.hobt_id = t1.resource_associated_entity_id
  19. LEFT OUTER JOIN sys.allocation_units a1 on a1.allocation_unit_id = t1.resource_associated_entity_id
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement