The MERGE That Would Not Update: A NULL in Your Change Detection
A MERGE upsert skips a NULL-to-value change and updates nothing, with no error. The three-valued-logic cause and two NULL-safe fixes.
Can You Delete That Certificate? The Store Will Not Tell You.
There is a certificate in LocalMachine\My on one of your SQL Servers. Nobody knows what it is for. The subject is unhelpful, it was issued before you started, and the person who installed it has…
Your Agent Forgets Everything. I Measured What I Forgot to Write Down.
An agent session ends and the context is gone. Everything it learned about your environment, every approach it tried and discarded, every decision you talked through together, and whatever it was about to do next….
A Plan Analysis Skill That Refuses to Let You Cite Cost
I have been testing the rules in my own T-SQL style guide against real instances, which means reading a lot of execution plans. Partway through, I started using Erik Darling’s sqlserver-query-plans plugin[1] for the reading….
Why I Keep a T-SQL Style Guide, and What Testing It Cost Me
I keep a file of T-SQL conventions. Square brackets on identifiers, COALESCE over ISNULL, block comments, NOT EXISTS over NOT IN, and a dozen more. It is not there because consistent code is prettier. It…
The SET Succeeds and the Catalog Read Succeeds, Then Msg 3951
Snapshot isolation is the answer to most of the problems WITH (NOLOCK) gets used for, which I covered in . Readers stop waiting for writers, and unlike read uncommitted, everything they read was actually committed….