• By the same token, there is a type of duplicate index that can provide huge performance increases.  They usually (but not always) are considered to be
    "Covering Indexes".  You can have the "perfect" Clustered Index for your query but, unless you're using a huge number of columns from a very wide table in your query, a much narrower Non-Clustered Index with the exact same key as the Clustered Index and the correct INCLUDES (think of it as being very similar to a much smaller Clustered Index) can make the queries that use the Non-Clustered Index absolutely fly compared to when the query uses the Clustered Index simply because of the greatly reduced page count thanks to more rows per page in the Non_Clustered Index.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)