How to compress an existing tablespace and all the preexisting data in it?
655447Aug 23 2011 — edited May 31 2012Hi all,
Thats my question. I have a 11.2.0.1 database on Red Hat x86 without compression (this is a test machine and data are not important). I desire turn tablespaces comprised and all the data existing prior to compression was activated. The goal is to get all the data comprised for make some test and take references about space profit and throughput benefit.
I have seen this sentences for activate compression:
create table fred (col1 number) NOCOMPRESS;
create table fred (col1 number) COMPRESS FOR DIRECT_LOAD OPERATIONS;
create table fred (col1 number) COMPRESS FOR ALL OPERATIONS;
alter table fred move COMPRESS;
CREATE TABLESPACE MYSTUFF . . . DEFAULT { COMPRESS [ FOR { ALL | DIRECT_LOAD } OPERATIONS ] | NOCOMPRESS }
I've tried to use the "alter table table_name move compress;" and go for review if the space consumed was reduced. No difference between before and after space. How can i do this taks without rebuilt the tablespaces?
Regards in advance,
A newby