Compare wait stats snapshots over a chosen window, subtract cumulative counters, remove background waits, and calculate rates and average waits.
Seeing What Is Running Right Now
See what is running right now in SQL Server with request DMVs, statement text, plans, waits, and blocking details in one reusable query.
Recursive CTE Performance: Index the Child Lookup
Recursive CTE performance depends on finding the next children efficiently. Compare identical rows and actual plans before accepting an index change.
Trigger Overhead: Measuring the Hidden Cost of DML Triggers
Measure trigger overhead with controlled inserts, execution plans, and cached trigger statistics before moving slow work into a queue.
What Is an Index in SQL Server?
An index in SQL Server took one query from 33,517 reads to 66 on the same table. What clustered and nonclustered really mean, why every index is paid for on the way in, and how to find the ones nobody uses.
SQL SERVER – Converting Subqueries to Joins
Developers often write subqueries where Joins would do, or the other way around. A short note on converting between the two, with links to my earlier examples.
Checking XACT_STATE Before COMMIT or ROLLBACK in a CATCH Block
XACT_STATE separates transaction validity from the decision to retain work. Two isolated examples show a doomed transaction and a committable one, both with deliberate errors. Clean up on the same connection and respect the caller’s transaction ownership.







