THE SQL Server Blog Spot on the Web

Welcome to SQLblog.com - The SQL Server blog spot on the web Sign in | |
in Search

Browse by Tags

All Tags » Query Plans » Ranking functions   (RSS)
  • Ranking Function Optimizer Transformations

    In my last post I showed how SQL Server 2005 and later can use a Segment Spool to efficiently implement aggregate window functions and the NTILE ranking function. The query optimizer is also smart enough to recognise that some queries are logically equivalent to a window function, even if they are written using different syntax.  As a ...
    Posted to Page Free Space (Weblog) by Paul White on July 28, 2010
  • Partitioning and the Common Subexpression Spool

    SQL Server 2005 introduced the OVER clause to enable partitioning of rowsets before applying a window function.  This post looks at how this feature may require a query plan containing a 'common subexpression spool'.  This query plan construction is required whenever an aggregate window function or the NTILE ranking window function is ...
    Posted to Page Free Space (Weblog) by Paul White on July 27, 2010
Privacy Statement