Archive for October 15th, 2009
Continuing on from the yesterday's article.
I was wondering: do the constraints declared on tables in SQL Server affect the decisions made by the optimizer?
SQL Server allows to define the following constraints on the columns:
Today we will see how
FOREIGN KEY affect the plans.
A FOREIGN KEY guarantees that every value of the column constrained with it is contained in a PRIMARY KEY or
UNIQUE column of another table.
This fact can be used to simpify joins on these columns and using
Let's create the sample tables:
Read the rest of this entry »