SQL Server 2005:将 Transaction_ID 映射到 @@SPID [英] SQL Server 2005 : map Transaction_ID to @@SPID

查看:23
本文介绍了SQL Server 2005:将 Transaction_ID 映射到 @@SPID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

无论如何,是否可以将 transaction_id 从诸如 sys.dm_tran_active_transactions 之类的地方映射到 SQL Server 2005 中的 SPID?

Is there anyway to map transaction_id from somewhere like sys.dm_tran_active_transactionsto an SPID in SQL Server 2005?

推荐答案

这听起来很明显,但前两列记录了 sys.dm_tran_session_transactionssession_idtransaction_id.这是在事务和会话之间映射的表.

It may sound obvious, but the first two columns documented for sys.dm_tran_session_transactions are session_id and transaction_id. This is the table that maps between transactions and sessions.

这篇关于SQL Server 2005:将 Transaction_ID 映射到 @@SPID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆