mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 23:05:15 +00:00
5fb50fa2cb
backtest: add ftx kline table
31 lines
971 B
SQL
31 lines
971 B
SQL
-- +up
|
|
-- +begin
|
|
|
|
CREATE TABLE `ftx_klines`
|
|
(
|
|
`gid` INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
`exchange` VARCHAR(10) NOT NULL,
|
|
`start_time` DATETIME(3) NOT NULL,
|
|
`end_time` DATETIME(3) NOT NULL,
|
|
`interval` VARCHAR(3) NOT NULL,
|
|
`symbol` VARCHAR(7) NOT NULL,
|
|
`open` DECIMAL(16, 8) NOT NULL,
|
|
`high` DECIMAL(16, 8) NOT NULL,
|
|
`low` DECIMAL(16, 8) NOT NULL,
|
|
`close` DECIMAL(16, 8) NOT NULL DEFAULT 0.0,
|
|
`volume` DECIMAL(16, 8) NOT NULL DEFAULT 0.0,
|
|
`closed` BOOLEAN NOT NULL DEFAULT TRUE,
|
|
`last_trade_id` INT NOT NULL DEFAULT 0,
|
|
`num_trades` INT NOT NULL DEFAULT 0,
|
|
`quote_volume` DECIMAL NOT NULL DEFAULT 0.0,
|
|
`taker_buy_base_volume` DECIMAL NOT NULL DEFAULT 0.0,
|
|
`taker_buy_quote_volume` DECIMAL NOT NULL DEFAULT 0.0
|
|
);
|
|
-- +end
|
|
|
|
-- +down
|
|
|
|
-- +begin
|
|
drop table ftx_klines;
|
|
-- +end
|