After the first SQLSaturday in Sri Lanka, here is a question worth a script: how many lines of code do you have in your database? Here is a way to count them.
SQL SERVER – Puzzle with Year Function
After my MONTH() contest, here is a puzzle with YEAR function: what do MONTH and YEAR return for the date 0001-1-1, and why? Take a guess first.
SQL SERVER – What are T-SQL Window Functions? – Notes from the Field #082
Kathi Kellenberger, one of my favorite SQL authors, explains what T-SQL window functions are and how the OVER clause works in SQL Server.
SQL SERVER – Adding Reference Data to Master Data Services – Notes from the Field #081
Reeves Smith shows how to add reference data to Master Data Services with the MDS add-in for Excel, so the business can manage it themselves.
Interview Question of the Week #020 – What is the Difference Between DISTINCT and GROUP BY?
Explain the difference between DISTINCT and GROUP BY with a self-contained demo, HAVING filters, and a correlated-subquery plan comparison.





