Setting up compression on TimescaleDB requires users to first configure the hypertable for compression and then for when to compress chunks.

    Compressed chunks have the following limitations:

    • is not supported.
    • Constraints are not fully supported:
      • Unique constraints (UNIQUE) are restricted to compression SEGMENTBY and ORDER BY columns.
      • Constraints are restricted to compression SEGMENTBY columns when applicable. Otherwise they are unsupported.

    Starting with TimescaleDB 2.1, users have the ability to modify the schema of hypertables that have compressed chunks. Specifically, you can add columns to and rename existing columns of such compressed hypertables.

    Altering data of compressed chunks still has some limitations:

    • You cannot execute UPDATE or DELETE statements on compressed chunks.
    • INSERT is not fully supported on compressed chunks:
      • You cannot use the ON CONFLICT clause, that is, upserts are not supported.
      • You cannot use the RETURNING clause.
    • Triggers are not fully supported when inserting into compressed chunks:
      • You cannot use AFTER INSERT row-level triggers (FOR EACH ROW).
    • Constraints are not fully supported when inserting into compressed chunks:
      • Primary Keys (PRIMARY KEY) are not supported.