Write SARGable date filters as half-open ranges for years, months, days, and rolling windows, then compare plans and logical reads.
SQL SERVER – Preserve Leading Zero While Coping to Excel from SSMS
Want to preserve leading zero values when you paste SSMS results into Excel? The fix is in Excel: format the cells as Text first, and the zeros stay.
Why CAST to a Short VARCHAR Returns a Star Instead of an Error
Understand why a short VARCHAR returns a star for an integer, compare Unicode errors and string truncation, and size conversions safely.
Fuzzy Name Matching With SOUNDEX and DIFFERENCE
SOUNDEX and DIFFERENCE can surface duplicate customers, and they can also flag people who only sound alike. Here is how I keep the review honest.
REGEXP_COUNT in SQL Server 2025: Counting Pattern Matches in Text
REGEXP_COUNT counts how many times a pattern matches inside a text value, a job that used to need LEN and REPLACE tricks. This post tests it on SQL Server 2025: start position, flags, NULL and empty text, a data quality check, and where the old trick still fits.
Measuring Time Between Workflow Steps With LEAD
Status rows hold timestamps, not durations. I use LEAD to measure each step, keep unfinished steps NULL, and show why zero ruins your averages.
PARSENAME for Dotted Values: Build Numbers and Object Names
Why does revision 12 sort before 7? Because the parts are text. Here is how PARSENAME fixes it, and where it trips you up.







