Home Forums SQL Server 2005 Administering Adding columns to a Index As key Vs Non-key columns RE: Adding columns to a Index As key Vs Non-key columns

  • curious_sqldba (7/25/2013)


    If space is not an issue, which one is preferred, adding all columns to the key column of index or adding on the searchable columns as key and rest in include columns?

    Neither.

    Design you indexes to support your queries. The queries that run against the tables will guide your index design.

    http://www.sqlservercentral.com/articles/Indexing/68439/

    http://www.sqlservercentral.com/articles/Indexing/68563/

    http://www.sqlservercentral.com/articles/Indexing/68636/

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass