Multivalue Compression Example - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
ft:locale
en-US
ft:lastEdition
2024-12-11
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905

The following CREATE TABLE fragment specifies that all occurrences of 'cashier', 'manager', and 'programmer' for the jobtitle column and all nulls are to be compressed to zero space.

Nulls are compressed by default whether or not there is an argument to the COMPRESS attribute specified for a column.

This definition saves 30 bytes for each row whenever an employee has one of the following job titles:

  • Null
  • Cashier
  • Manager
  • Programmer
     CREATE TABLE employee (
       employee_number INTEGER
       ...
       jobtitle        CHARACTER(30) COMPRESS (’cashier’,
                       ’manager’, ’programmer’)
       ...
       );