View Single Post

   
  #5 (permalink)  
Old 02-28-2008, 06:13 PM
Gert-Jan Strik
 
Posts: n/a
Default Re: sp_spaceused - too much unused space

Erland Sommarskog wrote:
>
> Gert-Jan Strik (sorry@toomuchspamalready.nl) writes:
> > If your table does not have a clustered index, you can temporarily add
> > one, just for the purpose of DBCC DBREINDEX, or you can change one of
> > your existing indexes to be the clustered one.

>
> Actually, wouldn't just adding a clustered index and then dropping it
> have the same effect as a DBCC DBREINDEX? <snip>


Yes it would. Of course, DBCC DBREINDEX on a table is less expensive
than adding a clustered index to a heap and then removing it again. The
DBCC DBREINDEX time is the same as the time it takes to add a clustered
index. However, the removal of the clustered index can take quite some
time, even more time than it takes to add the index.

So I agree with you that Brad should consider adding a permanent
clustered index.

Gert-Jan
Reply With Quote