QuestDB offers the option to elect a column as a designated timestamp. This allows you to specify which column the tables will be indexed by in order to leverage time-oriented language features and high-performance functionalities.
A designated timestamp is elected by using the
- during a CREATE TABLE operation
- during a SELECT operation
- when ingesting data via ILP, for tables that do not already exist in QuestDB,
partitions are applied automatically by day by default with a
- The native timestamp format used by QuestDB is a Unix timestamp in microsecond resolution. See Timestamps in QuestDB for more details.
- Only a column of type
timestampcan be elected as a designated timestamp.
- Only one column can be elected for a given table.
#Checking the designated timestamp settings
The meta functions,
table_columns(), are designed to show the designated timestamp settings of the
#Advantages of electing a designated timestamp
Electing a designated timestamp allows you to:
- Partition tables by time range. For more information, see the partitions reference.
- Use time series joins such as
ASOF JOIN. For more information, see the JOIN reference.
As of version 6.0.0, QuestDB supports the ingestion of records that are out-of-order (O3) by time. QuestDB detects and adjusts data ingestion for O3 data automatically and no manual configuration is required.