SAP Hana - Compression (In Column Store)

About

Compression algorithms (dictionary, RLE, sparse, and so on) applied to a table store column.

The compression are only on the main storage

Value

Default - Dictionary compression

Default is the Dictionary compression

  • applied to all columns
  • mapping of distinct column values to consecutive numbers. More distinct value, more compression.

Others - Advanced compression

Each column can be further compressed using different compression methods:

  • prefix encoding (PREFIXED),
  • run length encoding (RLE),
  • cluster encoding (CLUSTERED),
  • sparse encoding (SPARSE),
  • and indirect encoding (INDIRECT).

Columns with the PAGE LOADABLE attribute are compressed with the NBit algorithm only.

Info

SELECT 
   SCHEMA_NAME, TABLE_NAME, COLUMN_NAME, COMPRESSION_TYPE, LOADED 
FROM
   PUBLIC.M_CS_COLUMNS 
WHERE
   SCHEMA_NAME='<your_schema>' and TABLE_NAME='<your_table>'

The columns of the selected table are listed with the type of compression applied. The following values are possible:

  • DEFAULT
  • SPARSE
  • PREFIXED
  • CLUSTERED
  • INDIRECT
  • RLE

Documentation / Reference


Powered by ComboStrap