Unix Technical Forum

Row compression with range partitioned table

This is a discussion on Row compression with range partitioned table within the DB2 forums, part of the Database Server Software category; --> Greetings! I have a table which is range-partitioned by a date column (one year per table-partition). Currently there are ...


Go Back   Unix Technical Forum > Database Server Software > DB2

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-01-2008, 01:28 PM
Damir
 
Posts: n/a
Default Row compression with range partitioned table

Greetings!
I have a table which is range-partitioned by a date column (one year per
table-partition).
Currently there are five table partitions (second number is the number of
rows per table-partition):
TAB_2006 338333
TAB_2007 127239
TAB_2008 174718
TAB_2009 1
TAB_2010 0
so, they all contain records except the last partition which is currently
empty (and will be empty for some time...).

The table itself was created with the option "COMPRESS YES", along with all
partitions, and then the data was loaded into the table.
No table-partitions were added (attached) afterwards.

When I try the command:
db2 reorg table [partitioned-table] resetdictionary;
I get the warning message:
SQL2220W The compression dictionary was not built for one or more data
objects.
The db2.nfy shows the following:
ADM5591W A compression dictionary could not be built for object "6" in
tablespace "5" because no eligible data was found. If a dictionary existed
a-priori it will be used instead.

The statistics for the table show that there is no compression at all in the
table:

AVGROWSIZE AVGCOMPRESSEDROWSIZE PCTPAGESSAVED AVGROWCOMPRESSIONRATIO
PCTROWSCOMPRESSED
---------- -------------------- ------------- ------------------------ ------------------------
612 0 0 +0,00000E+000
+0,00000E+000


What could be the problem here, why does the row compression not work?
Because of the empty table partition?
Because I don't read the table stats the right way?

Any ideas?

Regards,
Damir



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 03-01-2008, 05:21 PM
Serge Rielau
 
Posts: n/a
Default Re: Row compression with range partitioned table

Damir,

I don't think you have an issue here.
What you got was a warning, not an error. It looks like you got
compressions for 2006-2008.
Note that in DB2 9.5 the remaining partitions will automatically be
compressed once sufficient data becomes available.

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 03-01-2008, 05:21 PM
Damir
 
Posts: n/a
Default Re: Row compression with range partitioned table

Serge,
thank you for the quick answer - the compression really did take place after
the reorg, I just failed to run the runstats :-)
So, after refreshing the stats the compression values indeed look very good
for the table:

AVGROWSIZE AVGCOMPRESSEDROWSIZE PCTPAGESSAVED AVGROWCOMPRESSIONRATIO
PCTROWSCOMPRESSED
---------- -------------------- ------------- ------------------------ ------------------------
173 173 71 +3,53826E+000
+1,00000E+002

Regards,
Damir



"Serge Rielau" <srielau@ca.ibm.com> wrote in message
news:62tcchF258nhsU1@mid.individual.net...
> Damir,
>
> I don't think you have an issue here.
> What you got was a warning, not an error. It looks like you got
> compressions for 2006-2008.
> Note that in DB2 9.5 the remaining partitions will automatically be
> compressed once sufficient data becomes available.
>
> Cheers
> Serge
> --
> Serge Rielau
> DB2 Solutions Development
> IBM Toronto Lab



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 02:10 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com