mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-17 02:32:56 +00:00
* build(deps): bump datafusion 20240528 Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * another update Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * update expected sqlness result Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * fix first/last value Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * reformat comment Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * fix remaining errors Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * revert toml format Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * fix pyo3 feature Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * remove dead code Signed-off-by: Ruihang Xia <waynestxia@gmail.com> * Apply suggestions from code review Co-authored-by: Jeremyhi <jiachun_feng@proton.me> * format file Signed-off-by: Ruihang Xia <waynestxia@gmail.com> --------- Signed-off-by: Ruihang Xia <waynestxia@gmail.com> Co-authored-by: Jeremyhi <jiachun_feng@proton.me>
80 lines
2.5 KiB
Plaintext
80 lines
2.5 KiB
Plaintext
CREATE TABLE integers(i BIGINT, ts TIMESTAMP TIME INDEX);
|
|
|
|
Affected Rows: 0
|
|
|
|
-- SQLNESS REPLACE (-+) -
|
|
-- SQLNESS REPLACE (\s\s+) _
|
|
-- SQLNESS REPLACE (RoundRobinBatch.*) REDACTED
|
|
-- SQLNESS REPLACE (Hash.*) REDACTED
|
|
-- SQLNESS REPLACE (peers.*) REDACTED
|
|
EXPLAIN SELECT DISTINCT i%2 FROM integers ORDER BY 1;
|
|
|
|
+-+-+
|
|
| plan_type_| plan_|
|
|
+-+-+
|
|
| logical_plan_| Sort: integers.i % Int64(2) ASC NULLS LAST_|
|
|
|_|_Aggregate: groupBy=[[integers.i % Int64(2)]], aggr=[[]]_|
|
|
|_|_MergeScan [is_placeholder=false]_|
|
|
| physical_plan | SortPreservingMergeExec: [integers.i % Int64(2)@0 ASC NULLS LAST]_|
|
|
|_|_SortExec: expr=[integers.i % Int64(2)@0 ASC NULLS LAST], preserve_partitioning=[true]_|
|
|
|_|_AggregateExec: mode=FinalPartitioned, gby=[integers.i % Int64(2)@0 as integers.i % Int64(2)], aggr=[] |
|
|
|_|_CoalesceBatchesExec: target_batch_size=8192_|
|
|
|_|_RepartitionExec: partitioning=REDACTED
|
|
|_|_AggregateExec: mode=Partial, gby=[integers.i % Int64(2)@0 as integers.i % Int64(2)], aggr=[]_|
|
|
|_|_RepartitionExec: partitioning=REDACTED
|
|
|_|_MergeScanExec: REDACTED
|
|
|_|_|
|
|
+-+-+
|
|
|
|
DROP TABLE integers;
|
|
|
|
Affected Rows: 0
|
|
|
|
CREATE TABLE test (a INTEGER, b INTEGER, t TIMESTAMP TIME INDEX);
|
|
|
|
Affected Rows: 0
|
|
|
|
-- SQLNESS REPLACE (-+) -
|
|
-- SQLNESS REPLACE (\s\s+) _
|
|
-- SQLNESS REPLACE (RoundRobinBatch.*) REDACTED
|
|
-- SQLNESS REPLACE (Hash.*) REDACTED
|
|
-- SQLNESS REPLACE (peers.*) REDACTED
|
|
EXPLAIN SELECT a, b FROM test ORDER BY a, b;
|
|
|
|
+-+-+
|
|
| plan_type_| plan_|
|
|
+-+-+
|
|
| logical_plan_| MergeScan [is_placeholder=false]_|
|
|
| physical_plan | MergeScanExec: REDACTED
|
|
|_|_|
|
|
+-+-+
|
|
|
|
-- SQLNESS REPLACE (-+) -
|
|
-- SQLNESS REPLACE (\s\s+) _
|
|
-- SQLNESS REPLACE (RoundRobinBatch.*) REDACTED
|
|
-- SQLNESS REPLACE (Hash.*) REDACTED
|
|
-- SQLNESS REPLACE (peers.*) REDACTED
|
|
EXPLAIN SELECT DISTINCT a, b FROM test ORDER BY a, b;
|
|
|
|
+-+-+
|
|
| plan_type_| plan_|
|
|
+-+-+
|
|
| logical_plan_| Sort: test.a ASC NULLS LAST, test.b ASC NULLS LAST_|
|
|
|_|_Aggregate: groupBy=[[test.a, test.b]], aggr=[[]]_|
|
|
|_|_MergeScan [is_placeholder=false]_|
|
|
| physical_plan | SortPreservingMergeExec: [a@0 ASC NULLS LAST,b@1 ASC NULLS LAST]_|
|
|
|_|_SortExec: expr=[a@0 ASC NULLS LAST,b@1 ASC NULLS LAST], preserve_partitioning=[true] |
|
|
|_|_AggregateExec: mode=FinalPartitioned, gby=[a@0 as a, b@1 as b], aggr=[]_|
|
|
|_|_CoalesceBatchesExec: target_batch_size=8192_|
|
|
|_|_RepartitionExec: partitioning=REDACTED
|
|
|_|_AggregateExec: mode=Partial, gby=[a@0 as a, b@1 as b], aggr=[]_|
|
|
|_|_RepartitionExec: partitioning=REDACTED
|
|
|_|_MergeScanExec: REDACTED
|
|
|_|_|
|
|
+-+-+
|
|
|
|
DROP TABLE test;
|
|
|
|
Affected Rows: 0
|
|
|