A script to sync logins between availability group replicas, keeping the SID so users do not orphan on failover. What to copy and what to check after.
Collapsing Repeated Spaces and Line Breaks With REGEXP_REPLACE
Tabs, line breaks and a sneaky character 160 can all hide in a name that looks fine. Here is how to clean them on purpose.
How Many Temporary Tables are Created So Far in SQL Server? – Interview Question of the Week #149
How many temporary tables are created so far in SQL Server? No DMV gives this directly, but here is an easy workaround to find the answer.
Partition Elimination: Proving a Query Reads Only What It Needs
Prove partition elimination with the actual plan, test date predicates, and use $PARTITION to check which slice SQL Server targets.







