Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8712

Re: SQL Server Compression and Proportional Fill

$
0
0

Hi,

 

the first question is, does this table has a BLOB column or not (e.g. NVARCHAR(MAX)). And if yes, is the BLOB column the one, that makes the table so big. If it has such a column (which I assume) it will not compress very well, as only the non-BLOB columns will compress.

You can try a different approach, which we use several times at other customers to move/compact such big tables.

 

<draft>

  • create a second filegroup with some files
  • run an create index command on that table and specify this new filegroup
    (CREATE INDEX ... WITH DROP_EXISTING ... TO FILEGROUP)
  • This will move the table from the current PRIMARY filegroup to the new files
  • Add files to your primary filegroup
  • Repeat the CREATE INDEX command and specify the PRIMARY filegroup again (and specify the compression flags)
  • This will move the table back to the PRIMARY filegroup and spread it over all files (including the new ones)
  • drop the new filegroup

</draft>

 

Best regards

  Clas


Viewing all articles
Browse latest Browse all 8712

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>