difference in stat collects on partition

Database
Enthusiast

difference in stat collects on partition

I encountered partion statistics in 13.10.  Can any one explain how it is different than the statistics collected on actula partion column?

I mean, the different in below statements -

collect stat on table (partition)

collect stats on table (partition column name)

Acutally i had a requirement on a table to add new partitions and when i submited the alter table statment it failed because of this partion stats. i had to drop these stats first and then recollect after adding new partions .  I wanted to know what is the advantage of this partion stats. did i make the right thing ?

1 REPLY

Re: difference in stat collects on partition

The partition stats tells the optimizer how many row partitions are empty, a histogram of how many rows are in each row partition, and the compression ratio for column partitions. This statistic is used for optimizer costing

Please see below for more details on partition stats -

http://developer.teradata.com/blog/carrie/2013/02/statistics-collection-recommendations-teradata-14-...