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

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Dead Locks in Sql server 2000
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

34 Posts

Posted - 07/05/2013 :  10:33:01  Show Profile  Reply with Quote
Hi, I have a stored procedure which reads records from temp table and insert into request table, at the same time my java code tries to update different row in the same table,i am getting below error in my java code...

Transaction (Process ID 190) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.

How to avoid these types of locks? is it posssible to lock the rows instead of table while insertion?

Flowing Fount of Yak Knowledge

United Kingdom
2179 Posts

Posted - 07/06/2013 :  03:51:07  Show Profile  Visit jackv's Homepage  Reply with Quote
Deadlocks occur because at least two tasks are blocing each other permanently. there are a few different ways of getting the deadlock detail .Once you've identified the deadlock - analyse the transaction logic and make more efficient , read more on detecting deadlocks

Jack Vamvas
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.02 seconds. Powered By: Snitz Forums 2000