SQL Server: What is the difference between Index Rebuilding and Index Reorganizing?

前端 未结 7 1255
暗喜
暗喜 2021-02-05 05:37

What is the difference between Index Rebuilding and Index Reorganizing?

相关标签:
7条回答
  • 2021-02-05 06:06

    "Reorganize index" is a process of cleaning, organizing, and defragmenting of "leaf level" of the B-tree (really, data pages).

    Rebuilding of the index is changing the whole B-tree, recreating the index.

    It’s recommended that index should be reorganized when index fragmentation is from 10% to 40%; if index fragmentation is great than 40%, it’s better to rebuild it.

    Rebuilding of an index takes more resources, produce locks and slowing performance (if you choose to keep table online). So, you need to find right time for that process.

    0 讨论(0)
提交回复
热议问题