Very good article Gary, I gave it five stars because you covered the ground with some excellent explanations. Two omissions stood out however - the cost of recompiling, and why oh why didn't you mention the keywords "parameter sniffing"?
I'll ask Adam to remind you of this next time you meet up. He sits next to me.
[font="Arial"]“Write the query the simplest way. If through testing it becomes clear that the performance is inadequate, consider alternative query forms.” - Gail Shaw[/font]
For fast, accurate and documented assistance in answering your questions, please read this article
Understanding and using APPLY, (I)[/url] and
(II)[/url] Paul White
Hidden RBAR: Triangular Joins[/url] /
The "Numbers" or "Tally" Table: What it is and how it replaces a loop[/url] Jeff Moden