June 6, 2009 at 1:00 pm
Hi guys
i found very funny situation when ever i run a select or update statement contaioning three involved in joining
when run sp_who2 i find in blk by column -2 , i donot understand why it is appering
what was wrong and how we can fix it.
June 6, 2009 at 1:24 pm
It's not your select that's the problem. You've got some orphaned DTC transactions that are holding locks.
To get rid of the locks, query sys.dm_os_tran_locks for rows where the requesting session_id is -2. There's a column towards the end of the view that contains a guid, called the Unit of Work (UOW) or similar. Pass that guid as a parameter to KILL.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
June 8, 2009 at 8:09 am
i did not find that dynamic view in the master.
still though i have mssql 2005 install
June 8, 2009 at 10:34 am
Sorry, os shouldn't have been there. sys.dm_tran_locks. Run it in the DB in question, not in master.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply