Tuesday, July 28, 2009

Claim Unused space from table after Deletion of rows of after droppping columns

If you deleted rows and space used is same as previous then first thing you need to do is Rebuild Clustered Index.
It will release most of the unused space.

Secondly if you have dropped any variable length column then you can run the mentioned below command.
DBCC CLEANTABLE (AdventureWorks,"Production.Document", 0)