Jie*_*ong 4 sql-server extended-events blocking
有没有办法确定正在等待的资源的类型/名称?
wait_info XE的wait_resource列是一个指针;我不知道有什么方法可以解码这个。
您可以尝试使用wait_completed事件,该事件还有一个更加人性化的wait_resource列。不过,它是可选的,因此请确保它已启用。
然后,您可以使用 Kendra 的文章Decoding Key and Page WaitResource for Deadlocks and Blocking来解码资源。
在这种情况下:
USE DbName /* Db with id = 5 */
SELECT
sc.name as schema_name,
so.name as object_name,
si.name as index_name
FROM sys.partitions AS p
JOIN sys.objects as so on
p.object_id=so.object_id
JOIN sys.indexes as si on
p.index_id=si.index_id and
p.object_id=si.object_id
JOIN sys.schemas AS sc on
so.schema_id=sc.schema_id
WHERE hobt_id = 72057594045923328;
GO
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
985 次 |
| 最近记录: |