October 27, 2006 at 4:47 am
Hi All,
I have got a very busy database, and a lot of users seem to run queries which then result into locks being hekld on the tables.
I have read articles on SQL 2005 to manage blocking, i.e using Try & Catch.
I was wondering if anyone knew of a way to Prevent locking in ones code ?
Thanks in advance
October 27, 2006 at 6:03 am
The whole point of a rdbms is the locking which assists in maintaining the integrity of the data. The art is to keep transactions as short and sharp as is possible. Without looking at code , readers take shared locks so default sql will have readers locking writers ( I'm assuming you're running out of the box ? ) You can use dirty reads , which turn off read locking, as long as the results you return do not have to be 100% critically correct - check out isolation levels to understand this.
Blocking is different to locking, ie it's a result of locking. Tuning the box will help - but it depends upon how big an issue you have.
[font="Comic Sans MS"]The GrumpyOldDBA[/font]
www.grumpyolddba.co.uk
http://sqlblogcasts.com/blogs/grumpyolddba/
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply