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.
| Author |
Topic |
|
CoffeeAddict
Yak Posting Veteran
94 Posts |
Posted - 2010-05-21 : 17:38:54
|
| is it not possible to do nolock on an update?update Transaction nolockset AuthID = RefundTransIDwhere id = 12569 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
Kristen
Test
22859 Posts |
Posted - 2010-05-22 : 01:58:02
|
| Do not use NOLOCK unless you know what its side effects are and your program is able to handle the errors that will be raised, and the fact that you may get duplicate rows, or missing rows returned.http://sqlblog.com/blogs/andrew_kelly/archive/2009/04/10/how-dirty-are-your-reads.aspxIf you have Reads blocking Writes then use READ_COMMITTED_SNAPSHOT instead (you just set that on the databases, so you don't then need NOLOCK hints anywhere in your code - but you will need to take ALL existing ones out because of the way they work, unless your program has been specifically built to handle those side effects) |
 |
|
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2010-05-22 : 04:40:19
|
| Read uncommitted only applies to reads (as it's name implies). All data modifications MUST lock exclusively to ensure database integrity.--Gail ShawSQL Server MVP |
 |
|
|
|
|
|