Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Doing a <code>REORGANIZE</code> and then a <code>REBUILD</code> on the same indexes is pointless, as any changes by the <code>REORGANIZE</code> would be lost by doing the <code>REBUILD</code>.</p> <p>Worse than that is that in the maintenance plan diagram from SSW, it performs a <code>SHRINK</code> first, which fragments the indexes as a side effect of the way it releases space. Then the <code>REBUILD</code> allocates more space to the database files again as working space during the <code>REBUILD</code> operation.</p> <ul> <li><p><code>REORGANIZE</code> is an online operation that defragments leaf pages in a clustered or non-clustered index page by page using little extra working space.</p></li> <li><p><code>REBUILD</code> is an online operation in Enterprise editions, offline in other editions, and uses as much extra working space again as the index size. It creates a new copy of the index and then drops the old one, thus getting rid of fragmentation. Statistics are recomputed by default as part of this operation, but that can be disabled.</p></li> </ul> <p>See <a href="http://msdn.microsoft.com/en-us/library/ms189858.aspx" rel="noreferrer">Reorganizing and Rebuilding Indexes</a> for more information.</p> <p>Don't use <code>SHRINK</code> except with the <code>TRUNCATEONLY</code> option and even then if the file will grow again then you should think hard as to whether it's necessary:</p> <p><a href="http://www.sqlservercentral.com/articles/SHRINKFILE/71414/" rel="noreferrer">sqlservercentral_SHRINKFILE</a> </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload