When you create a column-partitioned table or join index, Vantage attempts to use one or more methods to compress the data that you insert into the physical rows of the object unless you specify the NO AUTO COMPRESS option at the time you create the table or index or NO AUTO COMPRESS is set as the default. The process of selecting and applying appropriate compression methods to the physical containers of a column-partitioned table or join index is called autocompression.
Autocompression is most effective for a column partition with a single column and COLUMN format.
- Minimal CPU resources are required to decompress the data for reading.
- Vantage need not decompress a large number of values to find a single value.
Vantage applies autocompression for a physical row on a per container basis. For efficiency, the system may use the autocompression method chosen for the previous container, including not using autocompression, if that is more effective. Containers in a column partition may be autocompressed in different ways. Typically, the data type of a column is not a factor, and Vantage compresses values based only on their byte representation. The only difference to consider is whether the byte representation is fixed or variable length.
There are values for which no applicable compression techniques can reduce the size of the physical row, so Vantage does not compress the values for that physical row, but otherwise the system attempts to compress physical row values using one of the available autocompression methods. When you retrieve rows from a column-partitioned table, Vantage automatically decompresses any compressed column partition values as is necessary.
Because the selection of autocompression methods used for a container is made by Vantage and not by users, the methods that autocompression can select from to compress the data in a column partition are not documented in the Teradata user documentation library.