Chapter 2. “Yes, we are all individuals” A look at uniqueness in the world of SQL
Rob Farley
This chapter looks at the idea of uniqueness, in both database design and query design. I explain the ways in which uniqueness can be enforced and compare the features of each. I then examine the idea of uniqueness within datasets, and challenge some basic methods that people use to create GROUP BY clauses. I hope you gain a new appreciation for uniqueness so that you can echo the Monty Python team in shouting “Yes, we are all individuals!”
Note
For all my examples, I’ll use the AdventureWorks sample database, running on a SQL Server 2005 instance, connecting with SQL Server 2008 R2 Management Studio. I prefer the way that the later versions of SSMS ...
Get SQL Server MVP Deep Dives, Volume 2 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.