Brent Ozar 9/15/2026

“But NOLOCK won’t hurt me if I’m using an index!”

Read Original

Brent Ozar demonstrates that using NOLOCK with an index seek can still produce incorrect results. He creates a table with an index, runs an update transaction, and shows that a NOLOCK query with an index hint returns rows that should not exist. This proves that NOLOCK is unsafe even when using index seeks, due to the way SQL Server executes the query plan.

“But NOLOCK won’t hurt me if I’m using an index!”

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week

No top articles yet