This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
A sparrow leaving a birdbath taken by a big pigeon, flying toward a puddle beside a red tulip

SET LOCK_TIMEOUT and Error 1222: Waiting Less for Locks

September 13, 2012
Pinal Dave
SQL Performance
SQL Error Messages, SQL Lock, SQL Server, SQL Transactions

Set LOCK_TIMEOUT to bound lock waits, reproduce error 1222, clean up the transaction, and retry safely without confusing client timeouts.

Read More
Four ladders against separate apple trees in an orchard row, a full basket under each and one cart waiting at the end.

Loading Partitions in Parallel

March 26, 2012
Pinal Dave
SQL Tips and Tricks
ETL, Parallel, SQL Lock, SQL Server, Table Partitioning

Loading partitions in parallel uses separate staging tables, controlled workers, and partition switching to publish data without chaotic locks.

Read More
Two toy locomotives facing each other nose to nose on one wooden track, one red and one slate blue, neither able to pass.

Blocking and Deadlock Quiz: Which One Ends by Itself?

January 10, 2012
Pinal Dave
SQL Puzzle
Deadlock, SQL Error Messages, SQL Lock, SQL Transactions

This Blocking and Deadlock Quiz asks which problem SQL Server ends on its own, and how the losing session finds out. A two-window test on SQL Server 2025 shows the deadlock error 1205 and the lock timeout error 1222. It also shows how to find a blocker and how to retry.

Read More
A narrow wooden footbridge over a calm stream with a small red gate closing its entrance.

Locking and Blocking Quiz: Will Updating a Different Row Wait?

January 6, 2012
Pinal Dave
SQL Puzzle
SQL DMV, SQL Index, SQL Lock, SQL Performance

This Locking and Blocking Quiz asks whether an update waits when it changes a different row than an open transaction. The answer depends on the index. A two-window test on SQL Server 2025 shows the wait, the lock that causes it, and two ways to remove it.

Read More
A writing desk by a window with a half-written letter and a red fountain pen resting on it, an empty chair pulled up close.

ANSI Isolation Levels Quiz: Which Level Lets You Read Uncommitted Data?

January 2, 2012
Pinal Dave
SQL Puzzle
Snapshot, SQL Lock, SQL Transactions, Transaction Isolation

This ANSI Isolation Levels Quiz asks which level lets one session read a price that another session has not committed. A two-window test on SQL Server 2025 shows what each level returns. It also shows how READ COMMITTED SNAPSHOT removes the wait.

Read More
A hand checking the red wax seal on a jar of jam before opening it

Lost Updates: Optimistic Concurrency With a rowversion Column

October 18, 2011
Pinal Dave
SQL Tips and Tricks
SQL Lock, SQL Server, SQL Transactions, Transaction Isolation

Prevent lost updates with optimistic concurrency and a rowversion token, detect zero-row conflicts, and compare short locking transactions.

Read More
Comic strip: Casey trades the old booth cards for wristbands, but Jesse still waits on one milkshake party, ending up knitting a long scarf in a lawn chair as Quinn brings a fourth round. Casey says, "Optimized locking, same lesson. Bring the check sooner."

Optimized Locking Wait Stats: New Lock Waits in SQL Server 2025

February 24, 2011
Pinal Dave
SQL Performance
SQL DMV, SQL Lock, SQL Transactions, SQL Wait Stats

Optimized locking wait stats are the new lock waits SQL Server 2025 records when optimized locking is on. On Night 24 at the Clipboard Diner, a new state code swaps booth cards for wristbands. Then I show what LCK_M_S_XACT_MODIFY and LCK_M_S_XACT_READ mean, how to check the setting, and why a long transaction still hurts.

Read More
Previous 1 … 3 4 5 6 7 8 9 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com