crypto_quant/sql/query/sql_playground.sql

31 lines
897 B
SQL

select date_time, open, high, low, close, k_shape from crypto_market_data
WHERE symbol='XCH-USDT' and bar='5m' and date_time > '2025-08-04 15:00:00'
order by timestamp ;
select * from crypto_market_data
WHERE symbol='XCH-USDT' and bar='5m' and date_time > '2025-08-04 15:00:00'
order by timestamp desc;
delete FROM crypto_market_data where symbol != 'XCH-USDT';
select * from crypto_trade_data
where symbol='XCH-USDT'
order by ts desc;
select count(1) from crypto_trade_data;
select * from crypto_huge_volume
WHERE symbol='XCH-USDT' and bar='5m' and window_size = 80 and date_time > '2025-07-26'
order by timestamp;
select * from crypto_huge_volume
WHERE symbol='XCH-USDT-SWAP' and bar='5m' and date_time > '2025-07-26'
order by timestamp desc;
select * from crypto_huge_volume
WHERE symbol='BTC-USDT' and bar='5m'
order by timestamp desc
limit 10;
SHOW VARIABLES LIKE 'max_connections';