Wait statistics provide a starting point for investigation. Separate cumulative completed waits, background activity, signal time and currently waiting requests before treating the largest total as the present bottleneck.
SQL SERVER – Keywords View Definition Must Not Contain for Indexed View – Limitation of the View 10
A quick reference of the keywords a view definition must not contain if you want an indexed view in SQL Server, part 10 of my views series.
Finding the Nearest Location With a Spatial Index
A nearest location query in SQL Server needs TOP, STDistance in WHERE and ORDER BY, matching SRIDs, and a checked spatial plan.
Percent of Total With SUM() OVER() in One Query
Calculate percent of total with SUM() OVER(), group and running shares, safe numeric division, and checks for zero totals.
REPLACE With COLLATE: Choose Case Matching Explicitly
REPLACE with COLLATE controls which substrings match. Preview case-dependent results before applying a text replacement policy.
Contained Database Users: Logins That Move With the Database
Use contained database users to move authentication with a database, inspect prerequisites, test connections, and review access ownership.







