This topic describes the common terms that are used in Lindorm SQL.
The following table describes the terms supported in LindormTable and LindormTSDB.
Term | Supported by LindormTable | Supported by LindormTSDB | Description |
DATABASE | 〇 | 〇 | A database is a structured collection used to store and manage data. |
TABLE | 〇 | 〇 | A table is a structured data object used to store and organize specific data records. When you create a table, you must create a schema for the table. A table schema specifies the names and data types of columns in the table. Tables created in LindormTable are called wide tables. Table created in LindormTSDB are called time series tables. |
PRIMARY KEY | 〇 | 〇 | A primary key is used to uniquely identify a column or a set of columns for each record in a table. The value of the primary key is unique within a table and cannot be empty. In a wide table, the primary key consists of one or more columns. In a time series table, the primary key consists of a timestamp column and one or more tag columns. Important Take note of the following limits when you use the primary key columns in LindormTable:
|
TTL | 〇 | 〇 | Time To Live (TTL) is used to specify the validity period of data. In LindormTable, you can configure TTL for objects at different levels, such as databases or tables. In LindormTSDB, you can configure TTL only for databases. |
COMPACTION | 〇 | 〇 | Compaction is a data management technology used to optimize and reduce the size of database files to improve database performance. The compaction policy varies with the storage engine. |
INDEX | 〇 | ✖️ | An index is a data structure that is used to speed up data retrieval in a database and improve query performance. An index can be used to quickly access one or more columns in a table. You can quickly locate the data that you want to access based on a specific column value. LindormTable supports various indexes such as secondary indexes and search indexes. LindormTSDB does not support custom indexes. |
DYNAMIC COLUMN | 〇 | ✖️ | Dynamic columns are columns that are not explicitly specified when you create a wide table in LindormTable. However, you can dynamically write data to the columns in your business. In LindormTable, you can configure specific attributes when you create a table to specify whether dynamic columns are enabled for the table. |
MUTABILITY | 〇 | ✖️ | Mutability is a table attribute that is used to classify the write patterns for base tables and organize index data. For more information, see Secondary indexes. |
TAG | ✖️ | 〇 | A tag describes the characteristics of a data source that generates time series data and does not change over time. A tag consists of a tag key and a tag value, which are both a string. In the primary index of a time series table, all columns except for the timestamp column are considered tag columns. To meet your business requirements and improve query performance, you can specify a tag column as a primary key column when you create a time series table to explicitly specify the sharding rules of the table. |
FIELD | ✖️ | 〇 | Field columns indicate all columns except for the timestamp column and tag columns in a time series table. |
TIME SERIES | ✖️ | 〇 | A time series is the sequence of a metric of a data source over time. A time series is determined by the combination of a series of tag columns. |
DOWNSAMPLE | ✖️ | 〇 | Downsampling is method used to query data. When you need to query data within a long period and the raw data is sampled at a high frequency, you can perform downsampling to reduce the time granularity of the sampled data. For example, if the raw data is sampled on a secondly basis, you can perform a downsamlping query to query data that is sampled on an hourly basis. This way, the data points in the result set can be reduced. |