July 17, 2008 at 1:17 am
Will converting adhoc queris to stored procedures reduce deadlocks?
July 17, 2008 at 1:23 am
Just converting them to stored procs, probably not.
To fix deadlocks, you need to identify the cause of that deadlock and fix that. It's probably bad code, bad indexes or both
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
July 17, 2008 at 2:12 am
I would agree, straight conversion from Query to Stored Proc would not stop dead lock.
Rather get the queries working right then convert them to a stored procedure.
July 17, 2008 at 2:24 am
yes this will not stop deadlocks on its own there are a number of things you must do, look at the table and how they are set-up the code you can commit trans before starting a new one this will also help. there are many ways to reduce dead locks one of the ways is to use row level locking, however, as they will always be a part of life the best way is to identify the underling in application causes and make the appropriate changes to that.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply