• I also love Paul's articles on APPLY and would second that suggestion. If you own or have access to Microsoft SQL Server 2012 High-Performance T-SQL functions by Itzek Ben-Gen there is a great section called "Improved Parallelism with APPLY". It's a just a few pages of some very valuable information.

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001