~Subject: Tracking deadlocks
If you start SQL Server with trace flags -T3605 and -T1204 (not 1205),
you will get messages in the errorlog file regarding deadlocks similar to
the one shown below.
The 1204 trace flag should only be used for debugging deadlocks in your
application as it can seriously degrade performance.
====================== errorlog file ========================
*** Deadlock detected - process 16 trying to wait on process 41
Deadlock chain -->
LOCK REQUEST INITIATING DEADLOCK: LOGICAL:
EX_PAGE at 0xaac690
lockid=107001 spid=16 dbid=6
Process 41 waiting on Process 16 for resource: LOGICAL. Lock requested by
SH_PAGE at 0xac549c
lockid=106991 spid=41 dbid=6
BLOCKED by spid 16 with the following lock:
EX_PAGE Blocking at 0x20be7c0
lockid=106991 spid=16 dbid=6
pstat=0x0100 [ ]
VICTIM: process 41 ; pstat 0x0100 [ ] ; cputime = 26
Process 41 was selected as victim
Waking up victim process 41 (110 : 0x0100)
shared lock already hold by spid 16
exclusive lock requested by spid 41
page 107001Quote:>>>> spid 41 is waiting on spid 16 to finish
See the 10.0 Troubleshooting Guide 6-27 for how to identity object and indexQuote:>>>> it looks like that spid 41 already holds a lock
>>>> on page 107001, thus the deadlock can't be
Hope this helps,
Does anyone know how to retrieve error information when an error has
been raised using RAISERROR in a stored procedure?
I am performing a Data Driven Query and the Insert is achieved by
calling a stored procedure.
Under certain conditions, the SP code raises an error (which results in
the step failing as intended).
The problem is that I can't find a way of obtaining the Error Code /
Description and thus pass suitable information on to the user.
Any ideas would be gratefully received.
Sent via Deja.com