mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-08 06:12:55 +00:00
* fix: specify input ordering and distribution for prom plan Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * update sqlness result Signed-off-by: Ruihang Xia <waynestxia@gmail.com> --------- Signed-off-by: Ruihang Xia <waynestxia@gmail.com>
33 lines
1.3 KiB
Plaintext
33 lines
1.3 KiB
Plaintext
CREATE TABLE test(i DOUBLE, j TIMESTAMP TIME INDEX, k STRING PRIMARY KEY);
|
|
|
|
Affected Rows: 0
|
|
|
|
-- insert two points at 1ms and one point at 2ms
|
|
INSERT INTO test VALUES (1, 1, "a"), (1, 1, "b"), (2, 2, "a");
|
|
|
|
Affected Rows: 3
|
|
|
|
-- analyze at 0s, 5s and 10s. No point at 0s.
|
|
-- SQLNESS REPLACE (metrics.*) REDACTED
|
|
-- SQLNESS REPLACE (RoundRobinBatch.*) REDACTED
|
|
-- SQLNESS REPLACE (-+) -
|
|
-- SQLNESS REPLACE (\s\s+) _
|
|
TQL ANALYZE (0, 10, '5s') test;
|
|
|
|
+-+-+
|
|
| plan_type_| plan_|
|
|
+-+-+
|
|
| Plan with Metrics | PromInstantManipulateExec: range=[0..10000], lookback=[300000], interval=[5000], time index=[j], REDACTED
|
|
|_|_RepartitionExec: partitioning=REDACTED
|
|
|_|_PromSeriesNormalizeExec: offset=[0], time index=[j], filter NaN: [false], REDACTED
|
|
|_|_PromSeriesDivideExec: tags=["k"], REDACTED
|
|
|_|_SortExec: expr=[k@2 DESC NULLS LAST,j@1 DESC NULLS LAST], REDACTED
|
|
|_|_StreamScanAdapter { stream: "<SendableRecordBatchStream>", schema: [Field { name: "i", data_type: Float64, nullable: true, dict_id: 0, dict_is_ordered: false, metadata: {} }, Field { name: "j", data_type: Timestamp(Millisecond, None), nullable: false, dict_id: 0, dict_is_ordered: false, metadata: {"greptime:time_index": "true"} }, Field { name: "k", data_type: Utf8, nullable: true, dict_id: 0, dict_is_ordered: false, metadata: {} }] }, REDACTED
|
|
|_|_|
|
|
+-+-+
|
|
|
|
DROP TABLE test;
|
|
|
|
Affected Rows: 1
|
|
|