VAR, STDEVP, STDEV and VARP are statistical functions that also fit the aggregate function definition. A quick AdventureWorks example shows all four.
UNICODE: Supplementary Characters Depend on the Collation
UNICODE returns an integer for the first character, and supplementary-character support affects that integer. I make the collation explicit when interpreting those values. Otherwise the same visible input can produce a misleading comparison.
COALESCE Fallbacks: Empty Text Is Still a Supplied Value
COALESCE fallbacks keep empty text and spaces as supplied values. Apply an empty-value policy before choosing a display name.
Auditing Who Has sysadmin
Audit who has sysadmin in SQL Server, including direct members and Windows groups, then investigate nested access and forgotten logins.
SQL SERVER – What is – DML, DDL, DCL and TCL – Introduction and Examples
What are DML, DDL, DCL and TCL? A short introduction to the four groups of SQL commands, with examples like SELECT, CREATE, GRANT and COMMIT.
Conditional COUNT: ELSE 0 Counts Nonmatching Rows
Conditional COUNT includes zero when CASE returns it. I compare an omitted ELSE with a zero branch before aggregating. A no-match group and an empty input expose the difference from SUM.
SQL SERVER – 2005 – Change Compatibility Level – T-SQL Procedure
The safe way to change compatibility level in SQL Server 2005: single user mode, sp_dbcmptlevel, then multi user again, and how to check it.







