This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
A muffin tin with one empty cup, while two muffins are squeezed together into the cup next to it.

Relational Division in T-SQL: Customers Who Bought Every Product

August 2, 2010
Pinal Dave
SQL Tips and Tricks
SQL Joins, SQL Scripts, SQL Server, SQL Sub Query

Solve relational division with counts and double NOT EXISTS, then handle duplicates, NULL values, empty requirements, and exact matching.

Read More
SQL SERVER - Email from Blog Reader - Not a Potential Bug in SQL - Puzzle

SQL SERVER – Email from Blog Reader – Not a Potential Bug in SQL – Puzzle

December 13, 2008
Pinal Dave
SQL Puzzle
SQL Error Messages, SQL Scripts, SQL Sub Query

A reader was sure he found a severe bug that causes data discrepancy. Run his script and see why it is not a potential bug in SQL Server at all.

Read More
SQL SERVER - Correlated and Noncorrelated - SubQuery Introduction, Explanation and Example

SQL SERVER – Correlated and Noncorrelated – SubQuery Introduction, Explanation and Example

September 7, 2007
Pinal Dave
SQL Tips and Tricks
SQL Joins, SQL Scripts, SQL Sub Query

What is the difference between correlated and noncorrelated subqueries? I explain both kinds with simple AdventureWorks examples.

Read More
SQL SERVER - Fix: Error 130: Cannot perform an aggregate function on an expression containing an aggregate or a subquery

SQL SERVER – Fix: Error 130: Cannot perform an aggregate function on an expression containing an aggregate or a subquery

May 16, 2007
Pinal Dave
SQL Tips and Tricks
SQL Error Messages, SQL Function, SQL Scripts, SQL Sub Query

Error 130 says you cannot perform an aggregate function on an expression containing an aggregate, like AVG(COUNT()). A derived table gets around it.

Read More
SQL Server Interview Questions and Answers - Part 3

SQL Server Interview Questions and Answers Part 3

April 17, 2007
Pinal Dave
SQL Interview Questions and Answers
Database, Software Development, SQL Constraint and Keys, SQL Cursor, SQL Download, SQL Function, SQL Index, SQL Joins, SQL Scripts, SQL Server, SQL Server Security, SQL Stored Procedure, SQL Sub Query, SQL Trigger

Interview Questions and Answers Part 3 opens with NOLOCK: how the hint skips read locks, why that means dirty reads, and what it does for concurrency.

Read More
Previous 1 2
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com