我试图把一个与更新查询(NOLOCK):更新查询使用NOLOCK提示
UPDATE pth_patchLookup with(nolock) SET ScanDateTime = Getdate() WHERE RegID = 312
,但我得到了以下信息:
NoLock hint is supported only with Select statement and not with update, insert and delete.
是否有任何的方式,其中我可以在这个更新查询应用“NOLOCK”?
感谢所有帮助
通常'(NOLOCK)'通常不是你想要的......有副作用可能会让你感到惊讶。 'READ COMMITTED SNAPSHOT ISOLATION'可能会更好地向您提供您(可能)想要的内容,但它需要更改数据库。请参阅[本文](http://www.brentozar.com/isolation-levels-sql-server/)了解更多信息。 – bhamby
你想达到什么目的? – GarethD
@GarethD当有多个实例更新表时,有一个死锁发生(SQL错误1205) –