HFT Tables: Create Table

Creating an HFT Table

Syntax & Example
CREATE HFT TABLE testing_hft_table (
    timestamp  DOUBLE PRECISION 0,
    price      DOUBLE PRECISION 10,
    volume     DOUBLE PRECISION 2,
    side       DOUBLE PRECISION 0
) SYMBOL 6 TOP;

To create a High-Frequency Trading (HFT) table, define the table name followed by the column schema definition inside parentheses. Each column is specified with its name, data type (e.g. DOUBLE PRECISION), and its decimal scaling precision factor.

Following the schema parentheses, specify the table constraints:

  • SYMBOL <count>: Defines the id you assign to the trading symbol you are inserting. This symbol is further used to add strategies and indicators.
  • TOP: The TOP parameter defines whether the high-frequency trading (HFT) table will track, receive, and persist the Top of the Order Book (best ask price, best ask quantity, best bid price, and best bid quantity) data.