CREATE TABLE demo(host string, cpu double, memory double, ts TIMESTAMP time index);

Affected Rows: 0

INSERT INTO demo(host, cpu, memory, ts) values ('host1', 66.6, 1024, 1655276557000), ('host2', 88.8,  333.3, 1655276558000);

Affected Rows: 2

COPY DATABASE public TO '${SQLNESS_HOME}/demo/export/parquet/' WITH (FORMAT="parquet");

Affected Rows: 2

COPY DATABASE public TO '${SQLNESS_HOME}/demo/export/parquet_range/' WITH (FORMAT="parquet", start_time='2022-06-15 07:02:37.000Z', end_time='2022-06-15 07:02:37.1Z');

Affected Rows: 1

DELETE FROM demo;

Affected Rows: 2

SELECT * FROM demo ORDER BY ts;

++
++

COPY DATABASE public FROM '${SQLNESS_HOME}/demo/export/parquet/';

Affected Rows: 2

SELECT * FROM demo ORDER BY ts;

+-------+------+--------+---------------------+
| host  | cpu  | memory | ts                  |
+-------+------+--------+---------------------+
| host1 | 66.6 | 1024.0 | 2022-06-15T07:02:37 |
| host2 | 88.8 | 333.3  | 2022-06-15T07:02:38 |
+-------+------+--------+---------------------+

DELETE FROM demo;

Affected Rows: 2

COPY DATABASE public FROM '${SQLNESS_HOME}/demo/export/parquet_range/';

Affected Rows: 1

SELECT * FROM demo ORDER BY ts;

+-------+------+--------+---------------------+
| host  | cpu  | memory | ts                  |
+-------+------+--------+---------------------+
| host1 | 66.6 | 1024.0 | 2022-06-15T07:02:37 |
+-------+------+--------+---------------------+

DELETE FROM demo;

Affected Rows: 1

COPY DATABASE public FROM '${SQLNESS_HOME}/demo/export/parquet_range/' LIMIT 2;

Error: 2000(InvalidSyntax), Invalid SQL, error: limit is not supported

DROP TABLE demo;

Affected Rows: 0

