Dynamic SQL runs in its own scope, so a value only comes back if you ask twice. Here are the two mistakes that leave you with NULL.
Catch-All Queries and Optional Parameter Plan Optimization in SQL Server 2025
Compare catch-all queries with recompilation, parameterized dynamic SQL, and SQL Server 2025 optional parameter plan optimization.
SQL SERVER – Export Data From SSMS Query to Excel
This follow-up to copying results to Excel shows how to export data directly from an SSMS query to Excel using Results to File (CTRL + SHIFT + F).
How to Move Log File or MDF File in SQL Server? – Interview Question of the Week #208
Question: How to Move Log File or MDF File in SQL Server? Here are the steps I use to move a busy LDF or MDF file to a quieter drive.
Finding Free Time Slots in a Calendar With GENERATE_SERIES
Find free time slots with GENERATE_SERIES, exclude overlapping bookings, and merge busy intervals before calculating calendar gaps.






