Include column VS Index Size

  • Hi,

    I an wondered why Include column does not change the size of non-clustered index.

    As I know non-clustered index is combination of leaf and non-leaf noedes, and include column are stored in leaf node only, and if create a non-clustered index it effect the space used by respective table.

    So why include column does not increase the size of non-clustered index size.

    Please help me to understand this.

    Thanks

    Kuldeep panwar

  • Include columns will increase the size of nonclustered indexes.

    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
  • So why it is called that Include column does not increase non-cluster index size......

  • It will increase the size of the index, but only for leaf pages. The non-leaf pages of the index will be the same size as before.

    SQL DBA,SQL Server MVP(07, 08, 09) A socialist is someone who will give you the shirt off *someone else's* back.

  • panwar.jt (11/8/2012)


    So why it is called that Include column does not increase non-cluster index size......

    Where is that stated?

    Include columns won't increase the size of the index key (they're not part of the index key), but they will increase the size of the index as a whole.

    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

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply