This script is for SQL Server 2008 Enterprise Edition. Run the script in SSMS with "results to text". It will generate the compression statements for all tables and indexes for the database it which is run in. It creates the compression scripts in ascending order based on table/index size so smaller tables/indexes are compressed first creating additional space for larger tables/indexes to be compressed.
Estimate compression for all tables and indexes with both Row and Page
This will log output of estimate compression for both PAGE and ROW for all tables and indexes
2015-12-10 (first published: 2015-11-20)
2,332 reads