Home Dashboard Directory Help
Search

Inaccurate information about deprecation of NOLOCK and READUNCOMMITTED with UPDATE and DELETE by Erland Sommarskog


Status: 

Resolved
 as Won't Fix Help for as Won't Fix


2
0
Sign in
to vote
Type: Bug
ID: 778878
Opened: 2/9/2013 2:06:50 AM
Access Restriction: Public
0
Workaround(s)
view
0
User(s) can reproduce this bug

Description

The topic of Deprecated Database Engine Features says "Specifying NOLOCK or READUNCOMMITTED in the FROM clause of an UPDATE or DELETE statement."

The topic of Table Hints says about these two hints:
"For UPDATE or DELETE statements: This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature."

From what I can tell, this is in accurate. What is deprecated is to specify the hints for the *target table* where the hint makes no sense. If you join to other tables, you can still apply the hint for these. See the repro below.



Details
Sign in to post a comment.
Posted by Microsoft on 2/12/2013 at 12:34 PM
Thank you for submitting this, but... I think that Books Online is correct, however the deprecation event is not. I'm not sure if this should be a separate deprecation event, or if the text of the current event should be changed. I have found an open work item to evaluate what we want to do with a long list of deprecated items, and this item is on the list. So, I think for now, the correct action is to do nothing. Books Online is (I think) correct. And no one is going to work on the event until somebody decides to take further action. And getting rid of deprecated items is a low priority activity. Rick Byham.
Sign in to post a workaround.