The wait-stats report showed CXPACKET at 61 percent of all waits, so a well-meaning change set server MAXDOP to 1. The big report queries went from forty seconds to nine minutes overnight, and the actual problem — one missing index…
Database Topic Archive
SQL Server Articles
Wait statistics, tempdb, Query Store, Always On availability groups, and SQL Server operations notes.
The availability group failed over in nine seconds. The applications stayed down for six minutes. The listener's DNS record was still pointing at the old primary's IP, the connection strings lacked MultiSubnetFailover, and every client was happily waiting out a…
The finance report had run with NOLOCK for two years to 'avoid blocking.' Then a reconciliation found the same invoice counted twice in one run and missing in the next — no dirty data involved, just an allocation-ordered scan walking…
A well-meaning engineer created forty-one indexes straight from dm_db_missing_index_details. Write latency doubled, three of the new indexes were never read once, and twelve were duplicates of each other with different column order. The DMV is a hint engine, not a…
A staging table variable holding 180,000 rows was being planned as one row, and the join strategy built on that estimate took eleven minutes. Swapping one character — @ to # — took it to nine seconds. The actual differences,…
The storage team kept reporting a write burst every sixty seconds, and the database kept getting blamed for being badly written. It was the classic checkpoint doing exactly what recovery interval told it to do. How checkpoints actually schedule, and…
Error 824 at 03:12 on a Sunday: a torn page in the order history table, 40,000 orders unreadable, and a restore that would cost six hours of data. What CHECKDB actually checks, how to run it on a busy box,…
CPU at eleven percent, disks idle, and 1,200 connections timing out: the instance had burned through every worker thread and the queue was growing by the second. What worker threads actually are, what eats them, and why raising the ceiling…
The subscriber was forty-five minutes behind and the on-call message said replication was broken. Replication was not broken — one DELETE of two million rows was replaying as two million singleton statements through a single-threaded agent. How to read the…
The maintenance plan said ONLINE = ON, so the rebuild was supposed to be invisible. Instead it queued behind a nine-minute report, blocked every query on the orders table, and the Saturday morning checkout went down. How online rebuilds actually…