Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 Deadlock

Author  Topic 

gangadhara.ms
Aged Yak Warrior

549 Posts

Posted - 2011-03-15 : 21:57:13
Hi All,

While running the stored proc i got with the following error

Msg 1205, Level 13, State 52, Procedure emP_Extract_Data_To_DataStage, Line 32
Transaction (Process ID 98) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.

How do we trace which process made this deadlock and how to avoid this ?

Thanks In advance

Thanks,
Gangadhara MS
SQL Developer and DBA

lionofdezert
Aged Yak Warrior

885 Posts

Posted - 2011-03-16 : 05:20:01
http://connectsql.blogspot.com/2009/07/in-environment-where-more-then-one.html

--------------------------
http://connectsql.blogspot.com/
Go to Top of Page

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2011-03-16 : 06:57:52
Turn traceflag 1222 on. That will write a deadlock graph into the error log when a deadlock is encountered. Post the graph here along with the definition of the table and the indexes on it.
DBCC TRACEON(1222,-1)


--
Gail Shaw
SQL Server MVP
Go to Top of Page
   

- Advertisement -