v.19.10New Feature

Add New Column Codec: T64

Add new column codec: T64. Made for (U)IntX/EnumX/Data(Time)/DecimalX columns. It should be good for columns with constant or small range values. Codec itself allows enlarge or shrink data type without re-compression. #5557 (Artem Zuikov)
Introduces a new column codec named T64 optimized for (U)IntX, EnumX, Date(Time), and DecimalX columns, enhancing compression efficiency especially for columns with constant or small range values.

Why it matters

The T64 codec addresses the need for efficient storage of columns that have constant or limited range values by allowing dynamic adjustment of the underlying data type size without requiring recompression. This improves storage optimization and query performance for such data types.

How to use it

To use the T64 codec, specify it in the column definition within the table schema like so:

CREATE TABLE example (
column_name UInt32 CODEC(T64)
) ENGINE = ...


This enables the codec for the respective column, allowing ClickHouse to automatically manage data type size adjustments.