fn_get_sql() and DBCC INPUTBUFFER will be deprecated. Use sys.dm_exec_query_stats and sys.dm_exec_sql_text to see each recently executed T-SQL query.
SQL SERVER – Enable Automatic Statistic Update on Database
Automatic statistics updates respond to changing data and query needs. I inspect the setting and estimates before treating it as a tuning fix.
VALUES Type Inference: Cast Before Combining Rows
VALUES type inference chooses a common column type. Preserve formatting-sensitive text by making source conversions explicit before combination.
SQL SERVER – Query Optimization – Remove Bookmark Lookup – Remove RID Lookup – Remove Key Lookup – Part 3
Part 3 of how to Remove Bookmark Lookup, RID Lookup and Key Lookup. A covering index holds every column the query uses in SELECT, JOIN and WHERE.
The Implicit Conversion That Quietly Kills Your Index
Find an implicit conversion in your SQL Server plan, understand which value changes type, and match application parameters to indexed columns.
SQL SERVER – Queries Waiting for Memory Allocation to Execute
Find queries waiting for memory allocation with sys.dm_exec_query_memory_grants, plus wait_order and the query plan, when you suspect memory is short.
SQL SERVER – Query Optimization – Remove Bookmark Lookup – Remove RID Lookup – Remove Key Lookup – Part 2
Part 2 compares two ways to remove key lookup and remove RID lookup: a covering non-clustered index versus an index with included columns.







