Deadlock detection and recovery in SP

  • I was surfing around and found this blog post about error handling and found the code to be pretty interesting for deadlock detection/recovery.

    http://www.campbellassociates.ca/blog/PermaLink,guid,823bdca5-ec17-4689-ac0c-e653664164bf.aspx

    I'm no expert and wondered if this was considered a "good" method of doing it.

    Thanks for any input!

  • You would have to enable trace flag 1222 for deadlock trace output (see output in sql logs) This trace flag has got improvements over the flag on sql2k; you can read about this in BOL under Detecting and ending deadlocks topic. Profiler has got also "deadlock chain" event that helps with detecting the cause of the deadlock (BOL - Analysing deadlocks with sql profiler)

    Most probably the script in your link above works fine but still a deadlock should be rectified by correcting the piece of code that caused the deadlock.

    Hope this helps.

     

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply