diff --git a/.github/licenserc.yml b/.github/licenserc.yml index e1add7017983b..aec59e4f66d57 100644 --- a/.github/licenserc.yml +++ b/.github/licenserc.yml @@ -40,4 +40,5 @@ header: - "tidb-binlog/proto/go-binlog/secondary_binlog.pb.go" - "**/*.sql" - ".bazelversion" + - "build/image/.ci_bazel" comment: on-failure diff --git a/bindinfo/capture_test.go b/bindinfo/capture_test.go index d1f375a6b63d7..21b31c883e582 100644 --- a/bindinfo/capture_test.go +++ b/bindinfo/capture_test.go @@ -434,8 +434,9 @@ func TestUpdateSubqueryCapture(t *testing.T) { rows := tk.MustQuery("show global bindings").Rows() require.Len(t, rows, 1) bindSQL := "UPDATE /*+ hash_join(@`upd_1` `test`.`t1`), use_index(@`upd_1` `test`.`t1` `idx_b`), use_index(@`sel_1` `test`.`t2` ), use_index(@`sel_2` `test`.`t2` )*/ `test`.`t1` SET `b`=1 WHERE `b` = 2 AND (`a` IN (SELECT `a` FROM `test`.`t2` WHERE `b` = 1) OR `c` IN (SELECT `a` FROM `test`.`t2` WHERE `b` = 1))" + originSQL := "UPDATE `test`.`t1` SET `b`=1 WHERE `b` = 2 AND (`a` IN (SELECT `a` FROM `test`.`t2` WHERE `b` = 1) OR `c` IN (SELECT `a` FROM `test`.`t2` WHERE `b` = 1))" require.Equal(t, bindSQL, rows[0][1]) - tk.MustExec(bindSQL) + tk.MustExec(originSQL) require.Len(t, tk.Session().GetSessionVars().StmtCtx.GetWarnings(), 0) } diff --git a/br/pkg/gluetidb/glue.go b/br/pkg/gluetidb/glue.go index 06af5615ff451..abe239f7723dc 100644 --- a/br/pkg/gluetidb/glue.go +++ b/br/pkg/gluetidb/glue.go @@ -288,6 +288,8 @@ func (gs *tidbSession) CreateTable(ctx context.Context, dbName model.CIStr, tabl return errors.Trace(err) } gs.se.SetValue(sessionctx.QueryString, query) + // Disable foreign key check when batch create tables. + gs.se.GetSessionVars().ForeignKeyChecks = false // Clone() does not clone partitions yet :( table = table.Clone() if table.Partition != nil { diff --git a/build/image/.ci_bazel b/build/image/.ci_bazel new file mode 100644 index 0000000000000..6114f8bf17db9 --- /dev/null +++ b/build/image/.ci_bazel @@ -0,0 +1 @@ +build:ci --remote_cache=http://bazel-cache.pingcap.net:8080/tidb --remote_timeout="15s" diff --git a/build/image/README.md b/build/image/README.md new file mode 100644 index 0000000000000..b109968354940 --- /dev/null +++ b/build/image/README.md @@ -0,0 +1,7 @@ +## CI Image + +Here is the Dockerfile for the CI image. + +- ```base``` is the base image with golang, development tools and so on. +- ```centos7_jenkins``` is the production image with CI environment tool in tidb repo. it is based on ```base```. +- ```.ci_bazel``` is the global default bazel config. it tell bazel where to get cache. diff --git a/build/image/base b/build/image/base new file mode 100644 index 0000000000000..85c3dbba6816f --- /dev/null +++ b/build/image/base @@ -0,0 +1,44 @@ +# Copyright 2023 PingCAP, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM hub.pingcap.net/jenkins/centos7_jenkins + +USER root +WORKDIR /root + +ENV GOLANG_VERSION 1.19.5 +ENV GOLANG_DOWNLOAD_URL https://dl.google.com/go/go$GOLANG_VERSION.linux-amd64.tar.gz +ENV GOLANG_DOWNLOAD_SHA256 36519702ae2fd573c9869461990ae550c8c0d955cd28d2827a6b159fda81ff95 +ENV GOPATH /go +ENV GOROOT /usr/local/go +ENV PATH $GOPATH/bin:$GOROOT/bin:$PATH +ADD https://github.com/bazelbuild/bazel/releases/download/5.3.2/bazel-5.3.2-linux-x86_64 /usr/bin/bazel +ADD https://uploader.codecov.io/latest/linux/codecov /usr/bin/codecov +RUN curl https://setup.ius.io | sh || true && \ + chmod u+x /usr/bin/bazel && yum update -y && \ + yum install -y supervisor tree libcurl-devel gettext autoconf python-pip python3-pip patch git wget gcc python autoconf make curl-devel expat-devel gettext-devel openssl-devel zlib-devel perl-CPAN perl-devel && \ + git clone --depth=1 --branch=v2.37.2 https://github.com/git/git && cd git && yum remove -y git && make configure && ./configure --prefix=/usr/local && make -j16 install && cd .. && rm -rf git && \ + pip3 install s3cmd requests && pip3 install requests && \ + curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ + && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ + && tar -C /usr/local -xzf golang.tar.gz \ + && rm golang.tar.gz && \ + mkdir /go && chown jenkins:jenkins /go && \ + curl -fsSL "http://pingcap-dev.hk.ufileos.com/jenkins/jenkins-slave-docker-sqllogictest.tar.gz" | tar xz -C "/git" \ + && chown -R jenkins:jenkins /git && \ + chown jenkins:jenkins /usr/bin/bazel && \ + chown jenkins:jenkins /usr/bin/codecov && \ + chmod +x /usr/bin/codecov +USER jenkins +WORKDIR /home/jenkins diff --git a/build/image/centos7_jenkins b/build/image/centos7_jenkins new file mode 100644 index 0000000000000..0f56c705ca114 --- /dev/null +++ b/build/image/centos7_jenkins @@ -0,0 +1,24 @@ +# Copyright 2023 PingCAP, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM hub.pingcap.net/wangweizhen/base_image:go11920230111 +USER root +WORKDIR /root +COPY .ci_bazel /data/bazel +RUN mkdir -p /data/tikv1 /data/tikv2 /data/tikv3 /data/pd && \ + chown -R jenkins:jenkins /data +USER jenkins +WORKDIR /home/jenkins +RUN go install github.com/hawkingrei/bazel_collect@latest && \ + go install github.com/bazelbuild/bazel-gazelle/cmd/gazelle@latest diff --git a/distsql/distsql.go b/distsql/distsql.go index 3c65205f3d331..b88394b936bb3 100644 --- a/distsql/distsql.go +++ b/distsql/distsql.go @@ -42,7 +42,7 @@ func DispatchMPPTasks(ctx context.Context, sctx sessionctx.Context, tasks []*kv. ctx = WithSQLKvExecCounterInterceptor(ctx, sctx.GetSessionVars().StmtCtx) _, allowTiFlashFallback := sctx.GetSessionVars().AllowFallbackToTiKV[kv.TiFlash] ctx = SetTiFlashMaxThreadsInContext(ctx, sctx) - resp := sctx.GetMPPClient().DispatchMPPTasks(ctx, sctx.GetSessionVars().KVVars, tasks, allowTiFlashFallback, startTs, mppQueryID) + resp := sctx.GetMPPClient().DispatchMPPTasks(ctx, sctx.GetSessionVars().KVVars, tasks, allowTiFlashFallback, startTs, mppQueryID, sctx.GetSessionVars().ChooseMppVersion()) if resp == nil { return nil, errors.New("client returns nil response") } diff --git a/executor/brie.go b/executor/brie.go index 608cfd6336b52..96896c0eb0119 100644 --- a/executor/brie.go +++ b/executor/brie.go @@ -524,6 +524,8 @@ func (gs *tidbGlueSession) CreateTable(ctx context.Context, dbName model.CIStr, return err } gs.se.SetValue(sessionctx.QueryString, result.String()) + // Disable foreign key check when batch create tables. + gs.se.GetSessionVars().ForeignKeyChecks = false // Clone() does not clone partitions yet :( table = table.Clone() diff --git a/executor/builder.go b/executor/builder.go index 310e6920edacf..ddf67ffbacd50 100644 --- a/executor/builder.go +++ b/executor/builder.go @@ -3401,6 +3401,7 @@ func (b *executorBuilder) buildMPPGather(v *plannercore.PhysicalTableReader) Exe b.err = err return nil } + gather := &MPPGather{ baseExecutor: newBaseExecutor(b.ctx, v.Schema(), v.ID()), is: b.is, diff --git a/executor/executor_test.go b/executor/executor_test.go index 85d0dad290bb0..422956d045abe 100644 --- a/executor/executor_test.go +++ b/executor/executor_test.go @@ -2114,6 +2114,8 @@ func TestIncorrectLimitArg(t *testing.T) { tk.MustGetErrMsg(`execute stmt1 using @a;`, `[planner:1210]Incorrect arguments to LIMIT`) tk.MustGetErrMsg(`execute stmt2 using @b, @a;`, `[planner:1210]Incorrect arguments to LIMIT`) + tk.MustGetErrMsg(`execute stmt2 using @a, @b;`, `[planner:1210]Incorrect arguments to LIMIT`) + tk.MustGetErrMsg(`execute stmt2 using @a, @a;`, `[planner:1210]Incorrect arguments to LIMIT`) } func TestExecutorLimit(t *testing.T) { diff --git a/executor/mpp_gather.go b/executor/mpp_gather.go index eba5498f8869d..745d0de9e62f6 100644 --- a/executor/mpp_gather.go +++ b/executor/mpp_gather.go @@ -93,10 +93,14 @@ func (e *MPPGather) appendMPPDispatchReq(pf *plannercore.Fragment) error { if err != nil { return errors.Trace(err) } + logutil.BgLogger().Info("Dispatch mpp task", zap.Uint64("timestamp", mppTask.StartTs), zap.Int64("ID", mppTask.ID), zap.Uint64("QueryTs", mppTask.MppQueryID.QueryTs), zap.Uint64("LocalQueryId", mppTask.MppQueryID.LocalQueryID), zap.Uint64("ServerID", mppTask.MppQueryID.ServerID), zap.String("address", mppTask.Meta.GetAddress()), - zap.String("plan", plannercore.ToString(pf.ExchangeSender))) + zap.String("plan", plannercore.ToString(pf.ExchangeSender)), + zap.Int64("mpp-version", mppTask.MppVersion.ToInt64()), + zap.String("exchange-compression-mode", pf.ExchangeSender.CompressionMode.Name()), + ) req := &kv.MPPDispatchRequest{ Data: pbData, Meta: mppTask.Meta, diff --git a/executor/seqtest/prepared_test.go b/executor/seqtest/prepared_test.go index 5811a386f137d..3c0f180e54f22 100644 --- a/executor/seqtest/prepared_test.go +++ b/executor/seqtest/prepared_test.go @@ -826,6 +826,12 @@ func TestSetPlanCacheLimitSwitch(t *testing.T) { tk.MustExec("set @@global.tidb_enable_plan_cache_for_param_limit = ON;") tk.MustQuery("select @@global.tidb_enable_plan_cache_for_param_limit").Check(testkit.Rows("1")) + + tk.MustGetErrMsg("set @@global.tidb_enable_plan_cache_for_param_limit = '';", "[variable:1231]Variable 'tidb_enable_plan_cache_for_param_limit' can't be set to the value of ''") + tk.MustGetErrMsg("set @@global.tidb_enable_plan_cache_for_param_limit = 11;", "[variable:1231]Variable 'tidb_enable_plan_cache_for_param_limit' can't be set to the value of '11'") + tk.MustGetErrMsg("set @@global.tidb_enable_plan_cache_for_param_limit = enabled;", "[variable:1231]Variable 'tidb_enable_plan_cache_for_param_limit' can't be set to the value of 'enabled'") + tk.MustGetErrMsg("set @@global.tidb_enable_plan_cache_for_param_limit = disabled;", "[variable:1231]Variable 'tidb_enable_plan_cache_for_param_limit' can't be set to the value of 'disabled'") + tk.MustGetErrMsg("set @@global.tidb_enable_plan_cache_for_param_limit = open;", "[variable:1231]Variable 'tidb_enable_plan_cache_for_param_limit' can't be set to the value of 'open'") } func TestPlanCacheLimitSwitchEffective(t *testing.T) { diff --git a/executor/set_test.go b/executor/set_test.go index 01a2fc7979efc..c50105cf6fd63 100644 --- a/executor/set_test.go +++ b/executor/set_test.go @@ -2071,3 +2071,59 @@ func TestSetChunkReuseVariable(t *testing.T) { // error value tk.MustGetErrCode("set @@tidb_enable_reuse_chunk=s;", errno.ErrWrongValueForVar) } + +func TestSetMppVersionVariable(t *testing.T) { + store := testkit.CreateMockStore(t) + tk := testkit.NewTestKit(t, store) + tk.MustQuery("select @@session.mpp_version").Check(testkit.Rows("UNSPECIFIED")) + tk.MustExec("SET SESSION mpp_version = -1") + tk.MustQuery("select @@session.mpp_version").Check(testkit.Rows("-1")) + tk.MustExec("SET SESSION mpp_version = 0") + tk.MustQuery("select @@session.mpp_version").Check(testkit.Rows("0")) + tk.MustExec("SET SESSION mpp_version = 1") + tk.MustQuery("select @@session.mpp_version").Check(testkit.Rows("1")) + tk.MustExec("SET SESSION mpp_version = unspecified") + tk.MustQuery("select @@session.mpp_version").Check(testkit.Rows("unspecified")) + { + tk.MustGetErrMsg("SET SESSION mpp_version = 2", "incorrect value: 2. mpp_version options: -1 (unspecified), 0, 1") + } + { + tk.MustExec("SET GLOBAL mpp_version = 1") + tk.MustQuery("select @@global.mpp_version").Check(testkit.Rows("1")) + tk.MustExec("SET GLOBAL mpp_version = -1") + tk.MustQuery("select @@global.mpp_version").Check(testkit.Rows("-1")) + } +} + +func TestSetMppExchangeCompressionModeVariable(t *testing.T) { + store := testkit.CreateMockStore(t) + tk := testkit.NewTestKit(t, store) + tk.MustGetErrMsg( + "SET SESSION mpp_exchange_compression_mode = 123", + "incorrect value: `123`. mpp_exchange_compression_mode options: NONE, FAST, HIGH_COMPRESSION, UNSPECIFIED") + tk.MustQuery("select @@session.mpp_exchange_compression_mode").Check(testkit.Rows("UNSPECIFIED")) + + tk.MustExec("SET SESSION mpp_exchange_compression_mode = none") + tk.MustQuery("select @@session.mpp_exchange_compression_mode").Check(testkit.Rows("none")) + tk.MustExec("SET SESSION mpp_exchange_compression_mode = fast") + tk.MustQuery("select @@session.mpp_exchange_compression_mode").Check(testkit.Rows("fast")) + tk.MustExec("SET SESSION mpp_exchange_compression_mode = HIGH_COMPRESSION") + tk.MustQuery("select @@session.mpp_exchange_compression_mode").Check(testkit.Rows("HIGH_COMPRESSION")) + + { + tk.MustExec("SET GLOBAL mpp_exchange_compression_mode = none") + tk.MustQuery("select @@global.mpp_exchange_compression_mode").Check(testkit.Rows("none")) + } + { + tk.MustExec("SET mpp_version = 0") + tk.MustExec("SET mpp_exchange_compression_mode = unspecified") + require.Equal(t, len(tk.Session().GetSessionVars().StmtCtx.GetWarnings()), 0) + } + { + tk.MustExec("SET mpp_version = 0") + tk.MustExec("SET mpp_exchange_compression_mode = HIGH_COMPRESSION") + warnings := tk.Session().GetSessionVars().StmtCtx.GetWarnings() + require.Equal(t, len(warnings), 1) + require.Equal(t, warnings[0].Err.Error(), "mpp exchange compression won't work under current mpp version 0") + } +} diff --git a/executor/tiflashtest/BUILD.bazel b/executor/tiflashtest/BUILD.bazel index a9e7a5ee027c4..0e6244f1b2f90 100644 --- a/executor/tiflashtest/BUILD.bazel +++ b/executor/tiflashtest/BUILD.bazel @@ -14,6 +14,7 @@ go_test( "//config", "//domain", "//executor", + "//kv", "//meta/autoid", "//parser/terror", "//planner/core", diff --git a/executor/tiflashtest/tiflash_test.go b/executor/tiflashtest/tiflash_test.go index 531ca5fe41329..f2bb7232bbbfa 100644 --- a/executor/tiflashtest/tiflash_test.go +++ b/executor/tiflashtest/tiflash_test.go @@ -30,6 +30,7 @@ import ( "github.com/pingcap/tidb/config" "github.com/pingcap/tidb/domain" "github.com/pingcap/tidb/executor" + "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/parser/terror" plannercore "github.com/pingcap/tidb/planner/core" "github.com/pingcap/tidb/store/mockstore" @@ -629,10 +630,41 @@ func TestDispatchTaskRetry(t *testing.T) { require.NoError(t, err) tk.MustExec("set @@session.tidb_enforce_mpp=ON") require.Nil(t, failpoint.Enable("github.com/pingcap/tidb/store/mockstore/unistore/mppDispatchTimeout", "3*return(true)")) - tk.MustQuery("select count(*) from t").Check(testkit.Rows("4")) + tk.MustQuery("select count(*) from t group by b").Check(testkit.Rows("4")) require.Nil(t, failpoint.Disable("github.com/pingcap/tidb/store/mockstore/unistore/mppDispatchTimeout")) } +func TestMppVersionError(t *testing.T) { + store := testkit.CreateMockStore(t, withMockTiFlash(2)) + tk := testkit.NewTestKit(t, store) + tk.MustExec("use test") + tk.MustExec("drop table if exists t") + tk.MustExec("create table t(a int not null primary key, b int not null)") + tk.MustExec("alter table t set tiflash replica 1") + tk.MustExec("insert into t values(1,0),(2,0),(3,0),(4,0)") + tb := external.GetTableByName(t, tk, "test", "t") + err := domain.GetDomain(tk.Session()).DDL().UpdateTableReplicaInfo(tk.Session(), tb.Meta().ID, true) + require.NoError(t, err) + tk.MustExec("set @@session.tidb_enforce_mpp=ON") + { + item := fmt.Sprintf("return(%d)", kv.GetNewestMppVersion()+1) + require.Nil(t, failpoint.Enable("github.com/pingcap/tidb/store/mockstore/unistore/MppVersionError", item)) + } + { + err := tk.QueryToErr("select count(*) from t group by b") + require.Error(t, err) + } + require.Nil(t, failpoint.Disable("github.com/pingcap/tidb/store/mockstore/unistore/MppVersionError")) + { + item := fmt.Sprintf("return(%d)", kv.GetNewestMppVersion()) + require.Nil(t, failpoint.Enable("github.com/pingcap/tidb/store/mockstore/unistore/MppVersionError", item)) + } + { + tk.MustQuery("select count(*) from t group by b").Check(testkit.Rows("4")) + } + require.Nil(t, failpoint.Disable("github.com/pingcap/tidb/store/mockstore/unistore/MppVersionError")) +} + func TestCancelMppTasks(t *testing.T) { var hang = "github.com/pingcap/tidb/store/mockstore/unistore/mppRecvHang" store := testkit.CreateMockStore(t, withMockTiFlash(2)) @@ -1325,15 +1357,15 @@ func TestDisaggregatedTiFlashQuery(t *testing.T) { require.NoError(t, err) tk.MustQuery("explain select * from t1 where c1 < 2").Check(testkit.Rows( "PartitionUnion_10 9970.00 root ", - "├─TableReader_15 3323.33 root data:ExchangeSender_14", + "├─TableReader_15 3323.33 root MppVersion: 1, data:ExchangeSender_14", "│ └─ExchangeSender_14 3323.33 mpp[tiflash] ExchangeType: PassThrough", "│ └─Selection_13 3323.33 mpp[tiflash] lt(test.t1.c1, 2)", "│ └─TableFullScan_12 10000.00 mpp[tiflash] table:t1, partition:p0 keep order:false, stats:pseudo", - "├─TableReader_19 3323.33 root data:ExchangeSender_18", + "├─TableReader_19 3323.33 root MppVersion: 1, data:ExchangeSender_18", "│ └─ExchangeSender_18 3323.33 mpp[tiflash] ExchangeType: PassThrough", "│ └─Selection_17 3323.33 mpp[tiflash] lt(test.t1.c1, 2)", "│ └─TableFullScan_16 10000.00 mpp[tiflash] table:t1, partition:p1 keep order:false, stats:pseudo", - "└─TableReader_23 3323.33 root data:ExchangeSender_22", + "└─TableReader_23 3323.33 root MppVersion: 1, data:ExchangeSender_22", " └─ExchangeSender_22 3323.33 mpp[tiflash] ExchangeType: PassThrough", " └─Selection_21 3323.33 mpp[tiflash] lt(test.t1.c1, 2)", " └─TableFullScan_20 10000.00 mpp[tiflash] table:t1, partition:p2 keep order:false, stats:pseudo")) diff --git a/kv/BUILD.bazel b/kv/BUILD.bazel index 8b345f574336a..309251993d7f0 100644 --- a/kv/BUILD.bazel +++ b/kv/BUILD.bazel @@ -84,6 +84,7 @@ go_test( "@com_github_pingcap_kvproto//pkg/coprocessor", "@com_github_pingcap_kvproto//pkg/deadlock", "@com_github_pingcap_kvproto//pkg/kvrpcpb", + "@com_github_pingcap_tipb//go-tipb", "@com_github_stretchr_testify//assert", "@com_github_stretchr_testify//require", "@com_github_tikv_client_go_v2//oracle", diff --git a/kv/mpp.go b/kv/mpp.go index de0a8e8654528..3c86f435c02c4 100644 --- a/kv/mpp.go +++ b/kv/mpp.go @@ -16,11 +16,65 @@ package kv import ( "context" + "strconv" + "strings" "time" "github.com/pingcap/kvproto/pkg/mpp" + "github.com/pingcap/tipb/go-tipb" ) +// MppVersion indicates the mpp-version used to build mpp plan +type MppVersion int64 + +const ( + // MppVersionV0 supports TiFlash version [~, ~] + MppVersionV0 MppVersion = iota + + // MppVersionV1 supports TiFlash version [v6.6.x, ~] + MppVersionV1 + + // MppVersionV2 + // MppVersionV3 + + mppVersionMax + + newestMppVersion MppVersion = mppVersionMax - 1 + + // MppVersionUnspecified means the illegal or unspecified version, it only used in TiDB. + MppVersionUnspecified MppVersion = -1 + + // MppVersionUnspecifiedName denotes name of UNSPECIFIED mpp version + MppVersionUnspecifiedName string = "UNSPECIFIED" +) + +// ToInt64 transforms MppVersion to int64 +func (v MppVersion) ToInt64() int64 { + return int64(v) +} + +// ToMppVersion transforms string to MppVersion +func ToMppVersion(name string) (MppVersion, bool) { + name = strings.ToUpper(name) + if name == MppVersionUnspecifiedName { + return MppVersionUnspecified, true + } + v, err := strconv.ParseInt(name, 10, 64) + if err != nil { + return MppVersionUnspecified, false + } + version := MppVersion(v) + if version >= MppVersionUnspecified && version <= newestMppVersion { + return version, true + } + return MppVersionUnspecified, false +} + +// GetNewestMppVersion returns the mpp-version can be used in mpp plan +func GetNewestMppVersion() MppVersion { + return newestMppVersion +} + // MPPTaskMeta means the meta info such as location of a mpp task. type MPPTaskMeta interface { // GetAddress indicates which node this task should execute on. @@ -40,7 +94,8 @@ type MPPTask struct { ID int64 // mppTaskID StartTs uint64 MppQueryID MPPQueryID - TableID int64 // physical table id + TableID int64 // physical table id + MppVersion MppVersion // mpp version PartitionTableIDs []int64 IsDisaggregatedTiFlashStaticPrune bool @@ -54,6 +109,7 @@ func (t *MPPTask) ToPB() *mpp.TaskMeta { LocalQueryId: t.MppQueryID.LocalQueryID, ServerId: t.MppQueryID.ServerID, TaskId: t.ID, + MppVersion: t.MppVersion.ToInt64(), } if t.ID != -1 { meta.Address = t.Meta.GetAddress() @@ -94,9 +150,8 @@ type MPPClient interface { // ConstructMPPTasks schedules task for a plan fragment. // TODO:: This interface will be refined after we support more executors. ConstructMPPTasks(context.Context, *MPPBuildTasksRequest, time.Duration) ([]MPPTaskMeta, error) - // DispatchMPPTasks dispatches ALL mpp requests at once, and returns an iterator that transfers the data. - DispatchMPPTasks(ctx context.Context, vars interface{}, reqs []*MPPDispatchRequest, needTriggerFallback bool, startTs uint64, mppQueryID MPPQueryID) Response + DispatchMPPTasks(ctx context.Context, vars interface{}, reqs []*MPPDispatchRequest, needTriggerFallback bool, startTs uint64, mppQueryID MPPQueryID, mppVersion MppVersion) Response } // MPPBuildTasksRequest request the stores allocation for a mpp plan fragment. @@ -107,3 +162,56 @@ type MPPBuildTasksRequest struct { PartitionIDAndRanges []PartitionIDAndRanges } + +// ExchangeCompressionMode means the compress method used in exchange operator +type ExchangeCompressionMode int + +const ( + // ExchangeCompressionModeNONE indicates no compression + ExchangeCompressionModeNONE ExchangeCompressionMode = iota + // ExchangeCompressionModeFast indicates fast compression/decompression speed, compression ratio is lower than HC mode + ExchangeCompressionModeFast + // ExchangeCompressionModeHC indicates high compression (HC) ratio mode + ExchangeCompressionModeHC + // ExchangeCompressionModeUnspecified indicates unspecified compress method, let TiDB choose one + ExchangeCompressionModeUnspecified + + // RecommendedExchangeCompressionMode indicates recommended compression mode + RecommendedExchangeCompressionMode ExchangeCompressionMode = ExchangeCompressionModeFast + + exchangeCompressionModeUnspecifiedName string = "UNSPECIFIED" +) + +// Name returns the name of ExchangeCompressionMode +func (t ExchangeCompressionMode) Name() string { + if t == ExchangeCompressionModeUnspecified { + return exchangeCompressionModeUnspecifiedName + } + return t.ToTipbCompressionMode().String() +} + +// ToExchangeCompressionMode returns the ExchangeCompressionMode from name +func ToExchangeCompressionMode(name string) (ExchangeCompressionMode, bool) { + name = strings.ToUpper(name) + if name == exchangeCompressionModeUnspecifiedName { + return ExchangeCompressionModeUnspecified, true + } + value, ok := tipb.CompressionMode_value[name] + if ok { + return ExchangeCompressionMode(value), true + } + return ExchangeCompressionModeNONE, false +} + +// ToTipbCompressionMode returns tipb.CompressionMode from kv.ExchangeCompressionMode +func (t ExchangeCompressionMode) ToTipbCompressionMode() tipb.CompressionMode { + switch t { + case ExchangeCompressionModeNONE: + return tipb.CompressionMode_NONE + case ExchangeCompressionModeFast: + return tipb.CompressionMode_FAST + case ExchangeCompressionModeHC: + return tipb.CompressionMode_HIGH_COMPRESSION + } + return tipb.CompressionMode_NONE +} diff --git a/kv/version_test.go b/kv/version_test.go index 1a2aa30143d10..d0b0a810e3f45 100644 --- a/kv/version_test.go +++ b/kv/version_test.go @@ -17,6 +17,7 @@ package kv import ( "testing" + "github.com/pingcap/tipb/go-tipb" "github.com/stretchr/testify/assert" ) @@ -30,3 +31,57 @@ func TestVersion(t *testing.T) { assert.True(t, eq == 0) assert.True(t, MinVersion.Cmp(MaxVersion) < 0) } + +func TestMppVersion(t *testing.T) { + assert.Equal(t, int64(1), GetNewestMppVersion().ToInt64()) + { + v, ok := ToMppVersion("unspecified") + assert.True(t, ok) + assert.Equal(t, v, MppVersionUnspecified) + } + { + v, ok := ToMppVersion("-1") + assert.True(t, ok) + assert.Equal(t, v, MppVersionUnspecified) + } + { + v, ok := ToMppVersion("0") + assert.True(t, ok) + assert.Equal(t, v, MppVersionV0) + } + { + v, ok := ToMppVersion("1") + assert.True(t, ok) + assert.Equal(t, v, MppVersionV1) + } +} + +func TestExchangeCompressionMode(t *testing.T) { + assert.Equal(t, "UNSPECIFIED", ExchangeCompressionModeUnspecified.Name()) + { + a, ok := ToExchangeCompressionMode("UNSPECIFIED") + assert.Equal(t, a, ExchangeCompressionModeUnspecified) + assert.True(t, ok) + } + assert.Equal(t, "NONE", ExchangeCompressionModeNONE.Name()) + { + a, ok := ToExchangeCompressionMode("NONE") + assert.Equal(t, a, ExchangeCompressionModeNONE) + assert.True(t, ok) + } + assert.Equal(t, "FAST", ExchangeCompressionModeFast.Name()) + { + a, ok := ToExchangeCompressionMode("FAST") + assert.Equal(t, a, ExchangeCompressionModeFast) + assert.True(t, ok) + } + assert.Equal(t, "HIGH_COMPRESSION", ExchangeCompressionModeHC.Name()) + { + a, ok := ToExchangeCompressionMode("HIGH_COMPRESSION") + assert.Equal(t, a, ExchangeCompressionModeHC) + assert.True(t, ok) + } + // default `FAST` + assert.Equal(t, ExchangeCompressionModeFast, RecommendedExchangeCompressionMode) + assert.Equal(t, tipb.CompressionMode_FAST, RecommendedExchangeCompressionMode.ToTipbCompressionMode()) +} diff --git a/metrics/grafana/tidb_resource_control.json b/metrics/grafana/tidb_resource_control.json new file mode 100644 index 0000000000000..0d2634a0113c4 --- /dev/null +++ b/metrics/grafana/tidb_resource_control.json @@ -0,0 +1,2073 @@ +{ + "__inputs": [ + { + "name": "DS_TEST-CLUSTER", + "label": "test-cluster", + "description": "", + "type": "datasource", + "pluginId": "prometheus", + "pluginName": "Prometheus" + } + ], + "__requires": [ + { + "type": "grafana", + "id": "grafana", + "name": "Grafana", + "version": "7.5.11" + }, + { + "type": "panel", + "id": "graph", + "name": "Graph", + "version": "" + }, + { + "type": "datasource", + "id": "prometheus", + "name": "Prometheus", + "version": "1.0.0" + } + ], + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "${DS_TEST-CLUSTER}", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 1, + "id": null, + "links": [], + "panels": [ + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 11, + "panels": [], + "title": "Resource Unit", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "The total request unit cost for all resource groups.", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 0, + "y": 1 + }, + "hiddenSeries": false, + "id": 12, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]) + rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]) + rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "RU", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 12, + "y": 1 + }, + "hiddenSeries": false, + "id": 13, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]) + rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]) + rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "RU Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "The read request unit cost for all resource groups.", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 0, + "y": 8 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "hide": false, + "instant": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "RRU", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 12, + "y": 8 + }, + "hiddenSeries": false, + "id": 15, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_read_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "RRU Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "The write request unit cost for all resource groups.", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 15 + }, + "hiddenSeries": false, + "id": 16, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "WRU", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 15 + }, + "hiddenSeries": false, + "id": 17, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_unit_write_request_unit_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "WRU Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 23 + }, + "id": 18, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 0, + "y": 24 + }, + "hiddenSeries": false, + "id": 19, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_request_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name, type)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}-{{type}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_request_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}-total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "KV Request Count", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 7, + "w": 12, + "x": 12, + "y": 24 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_request_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name, type) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}-{{type}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_request_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}-total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "KV Request Count Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 31 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_read_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_read_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes Read", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "decimals": null, + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 31 + }, + "hiddenSeries": false, + "id": 22, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_read_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_read_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes Read Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "decimals": null, + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 39 + }, + "hiddenSeries": false, + "id": 23, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_write_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_write_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes Written", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 39 + }, + "hiddenSeries": false, + "id": 24, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_write_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_write_byte_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes Written Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 47 + }, + "hiddenSeries": false, + "id": 25, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_kv_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_kv_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "KV CPU Time", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "decimals": null, + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 47 + }, + "hiddenSeries": false, + "id": 26, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_kv_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_kv_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "KV CPU Time Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "decimals": null, + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 55 + }, + "hiddenSeries": false, + "id": 27, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_sql_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name)", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_sql_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "SQL CPU Time", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "${DS_TEST-CLUSTER}", + "description": "", + "editable": true, + "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "grid": {}, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 55 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "alignAsTable": true, + "avg": true, + "current": true, + "max": true, + "min": true, + "rightSide": true, + "show": true, + "total": false, + "values": true + }, + "lines": true, + "linewidth": 2, + "links": [], + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.5.10", + "pointradius": 5, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_sql_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) by (name) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "interval": "", + "intervalFactor": 2, + "legendFormat": "{{name}}", + "refId": "A", + "step": 40 + }, + { + "exemplar": true, + "expr": "sum(rate(resource_manager_resource_sql_cpu_time_ms_sum{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m])) / on() group_left() sum(rate(tidb_executor_statement_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\"}[1m]))", + "format": "time_series", + "hide": false, + "interval": "", + "intervalFactor": 2, + "legendFormat": "total", + "refId": "B", + "step": 40 + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "SQL CPU Time Per Query", + "tooltip": { + "msResolution": true, + "shared": true, + "sort": 0, + "value_type": "cumulative" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:869", + "format": "bits", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:870", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Resource", + "type": "row" + } + ], + "refresh": "30s", + "schemaVersion": 18, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": {}, + "datasource": "${DS_TEST-CLUSTER}", + "hide": 2, + "includeAll": false, + "label": "K8s-cluster", + "multi": false, + "name": "k8s_cluster", + "options": [], + "query": "label_values(pd_cluster_status, k8s_cluster)", + "refresh": 2, + "regex": "", + "sort": 1, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": {}, + "datasource": "${DS_TEST-CLUSTER}", + "hide": 2, + "includeAll": false, + "label": "tidb_cluster", + "multi": false, + "name": "tidb_cluster", + "options": [], + "query": "label_values(pd_cluster_status{k8s_cluster=\"$k8s_cluster\"}, tidb_cluster)", + "refresh": 2, + "regex": "", + "sort": 1, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": {}, + "datasource": "${DS_TEST-CLUSTER}", + "definition": "label_values(process_start_time_seconds{k8s_cluster=\"$k8s_cluster\",tidb_cluster=\"$tidb_cluster\", job=\"tidb\"}, instance)", + "hide": 0, + "includeAll": true, + "label": "instance", + "multi": false, + "name": "instance", + "options": [], + "query": "label_values(process_start_time_seconds{k8s_cluster=\"$k8s_cluster\",tidb_cluster=\"$tidb_cluster\", job=\"tidb\"}, instance)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-1h", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ], + "time_options": [ + "5m", + "15m", + "1h", + "6h", + "12h", + "24h", + "2d", + "7d", + "30d" + ] + }, + "timezone": "browser", + "title": "Test-Cluster-TiDB-Resource-Control", + "uid": "000000201", + "version": 1 +} diff --git a/parser/ast/dml.go b/parser/ast/dml.go index 4b14bdc1fbc69..a8b1474b405e6 100644 --- a/parser/ast/dml.go +++ b/parser/ast/dml.go @@ -358,8 +358,8 @@ const ( HintUse IndexHintType = iota + 1 HintIgnore HintForce - HintKeepOrder - HintNoKeepOrder + HintOrderIndex + HintNoOrderIndex ) // IndexHintScope is the type for index hint for join, order by or group by. @@ -390,10 +390,10 @@ func (n *IndexHint) Restore(ctx *format.RestoreCtx) error { indexHintType = "IGNORE INDEX" case HintForce: indexHintType = "FORCE INDEX" - case HintKeepOrder: - indexHintType = "KEEP ORDER" - case HintNoKeepOrder: - indexHintType = "NO KEEP ORDER" + case HintOrderIndex: + indexHintType = "ORDER INDEX" + case HintNoOrderIndex: + indexHintType = "NO ORDER INDEX" default: // Prevent accidents return errors.New("IndexHintType has an error while matching") } diff --git a/parser/ast/misc.go b/parser/ast/misc.go index 453da4f6dc34a..8d5ecd3fdb4de 100644 --- a/parser/ast/misc.go +++ b/parser/ast/misc.go @@ -3767,7 +3767,7 @@ func (n *TableOptimizerHint) Restore(ctx *format.RestoreCtx) error { } table.Restore(ctx) } - case "use_index", "ignore_index", "use_index_merge", "force_index", "keep_order", "no_keep_order": + case "use_index", "ignore_index", "use_index_merge", "force_index", "order_index", "no_order_index": n.Tables[0].Restore(ctx) ctx.WritePlain(" ") for i, index := range n.Indexes { diff --git a/parser/ast/misc_test.go b/parser/ast/misc_test.go index 36e8cb1ef002f..7379279d51567 100644 --- a/parser/ast/misc_test.go +++ b/parser/ast/misc_test.go @@ -228,18 +228,18 @@ func TestTableOptimizerHintRestore(t *testing.T) { {"IGNORE_INDEX(@sel_1 t1 c1)", "IGNORE_INDEX(@`sel_1` `t1` `c1`)"}, {"IGNORE_INDEX(t1@sel_1 c1)", "IGNORE_INDEX(`t1`@`sel_1` `c1`)"}, {"IGNORE_INDEX(t1@sel_1 partition(p0, p1) c1)", "IGNORE_INDEX(`t1`@`sel_1` PARTITION(`p0`, `p1`) `c1`)"}, - {"KEEP_ORDER(t1 c1)", "KEEP_ORDER(`t1` `c1`)"}, - {"KEEP_ORDER(test.t1 c1)", "KEEP_ORDER(`test`.`t1` `c1`)"}, - {"KEEP_ORDER(@sel_1 t1 c1)", "KEEP_ORDER(@`sel_1` `t1` `c1`)"}, - {"KEEP_ORDER(t1@sel_1 c1)", "KEEP_ORDER(`t1`@`sel_1` `c1`)"}, - {"KEEP_ORDER(test.t1@sel_1 c1)", "KEEP_ORDER(`test`.`t1`@`sel_1` `c1`)"}, - {"KEEP_ORDER(test.t1@sel_1 partition(p0) c1)", "KEEP_ORDER(`test`.`t1`@`sel_1` PARTITION(`p0`) `c1`)"}, - {"NO_KEEP_ORDER(t1 c1)", "NO_KEEP_ORDER(`t1` `c1`)"}, - {"NO_KEEP_ORDER(test.t1 c1)", "NO_KEEP_ORDER(`test`.`t1` `c1`)"}, - {"NO_KEEP_ORDER(@sel_1 t1 c1)", "NO_KEEP_ORDER(@`sel_1` `t1` `c1`)"}, - {"NO_KEEP_ORDER(t1@sel_1 c1)", "NO_KEEP_ORDER(`t1`@`sel_1` `c1`)"}, - {"NO_KEEP_ORDER(test.t1@sel_1 c1)", "NO_KEEP_ORDER(`test`.`t1`@`sel_1` `c1`)"}, - {"NO_KEEP_ORDER(test.t1@sel_1 partition(p0) c1)", "NO_KEEP_ORDER(`test`.`t1`@`sel_1` PARTITION(`p0`) `c1`)"}, + {"ORDER_INDEX(t1 c1)", "ORDER_INDEX(`t1` `c1`)"}, + {"ORDER_INDEX(test.t1 c1)", "ORDER_INDEX(`test`.`t1` `c1`)"}, + {"ORDER_INDEX(@sel_1 t1 c1)", "ORDER_INDEX(@`sel_1` `t1` `c1`)"}, + {"ORDER_INDEX(t1@sel_1 c1)", "ORDER_INDEX(`t1`@`sel_1` `c1`)"}, + {"ORDER_INDEX(test.t1@sel_1 c1)", "ORDER_INDEX(`test`.`t1`@`sel_1` `c1`)"}, + {"ORDER_INDEX(test.t1@sel_1 partition(p0) c1)", "ORDER_INDEX(`test`.`t1`@`sel_1` PARTITION(`p0`) `c1`)"}, + {"NO_ORDER_INDEX(t1 c1)", "NO_ORDER_INDEX(`t1` `c1`)"}, + {"NO_ORDER_INDEX(test.t1 c1)", "NO_ORDER_INDEX(`test`.`t1` `c1`)"}, + {"NO_ORDER_INDEX(@sel_1 t1 c1)", "NO_ORDER_INDEX(@`sel_1` `t1` `c1`)"}, + {"NO_ORDER_INDEX(t1@sel_1 c1)", "NO_ORDER_INDEX(`t1`@`sel_1` `c1`)"}, + {"NO_ORDER_INDEX(test.t1@sel_1 c1)", "NO_ORDER_INDEX(`test`.`t1`@`sel_1` `c1`)"}, + {"NO_ORDER_INDEX(test.t1@sel_1 partition(p0) c1)", "NO_ORDER_INDEX(`test`.`t1`@`sel_1` PARTITION(`p0`) `c1`)"}, {"TIDB_SMJ(`t1`)", "TIDB_SMJ(`t1`)"}, {"TIDB_SMJ(t1)", "TIDB_SMJ(`t1`)"}, {"TIDB_SMJ(t1,t2)", "TIDB_SMJ(`t1`, `t2`)"}, diff --git a/parser/hintparser.go b/parser/hintparser.go index a619d2a1c74f2..998d9b3823d08 100644 --- a/parser/hintparser.go +++ b/parser/hintparser.go @@ -70,7 +70,6 @@ const ( hintJoinOrder = 57352 hintJoinPrefix = 57353 hintJoinSuffix = 57354 - hintKeepOrder = 57400 hintLeading = 57410 hintLimitToCop = 57407 hintLooseScan = 57424 @@ -88,9 +87,9 @@ const ( hintNoHashJoin = 57362 hintNoICP = 57369 hintNoIndexMerge = 57366 - hintNoKeepOrder = 57401 hintNoMRR = 57368 hintNoMerge = 57364 + hintNoOrderIndex = 57401 hintNoRangeOptimization = 57370 hintNoSemijoin = 57374 hintNoSkipScan = 57372 @@ -98,6 +97,7 @@ const ( hintNthPlan = 57406 hintOLAP = 57413 hintOLTP = 57414 + hintOrderIndex = 57400 hintPartition = 57415 hintQBName = 57378 hintQueryType = 57390 @@ -151,29 +151,29 @@ var ( 57352: 17, // hintJoinOrder (135x) 57353: 18, // hintJoinPrefix (135x) 57354: 19, // hintJoinSuffix (135x) - 57400: 20, // hintKeepOrder (135x) - 57410: 21, // hintLeading (135x) - 57407: 22, // hintLimitToCop (135x) - 57375: 23, // hintMaxExecutionTime (135x) - 57388: 24, // hintMemoryQuota (135x) - 57363: 25, // hintMerge (135x) - 57382: 26, // hintMpp1PhaseAgg (135x) - 57383: 27, // hintMpp2PhaseAgg (135x) - 57367: 28, // hintMRR (135x) - 57356: 29, // hintNoBKA (135x) - 57358: 30, // hintNoBNL (135x) - 57412: 31, // hintNoDecorrelate (135x) - 57362: 32, // hintNoHashJoin (135x) - 57369: 33, // hintNoICP (135x) - 57366: 34, // hintNoIndexMerge (135x) - 57401: 35, // hintNoKeepOrder (135x) - 57364: 36, // hintNoMerge (135x) - 57368: 37, // hintNoMRR (135x) - 57370: 38, // hintNoRangeOptimization (135x) - 57374: 39, // hintNoSemijoin (135x) - 57372: 40, // hintNoSkipScan (135x) - 57389: 41, // hintNoSwapJoinInputs (135x) - 57406: 42, // hintNthPlan (135x) + 57410: 20, // hintLeading (135x) + 57407: 21, // hintLimitToCop (135x) + 57375: 22, // hintMaxExecutionTime (135x) + 57388: 23, // hintMemoryQuota (135x) + 57363: 24, // hintMerge (135x) + 57382: 25, // hintMpp1PhaseAgg (135x) + 57383: 26, // hintMpp2PhaseAgg (135x) + 57367: 27, // hintMRR (135x) + 57356: 28, // hintNoBKA (135x) + 57358: 29, // hintNoBNL (135x) + 57412: 30, // hintNoDecorrelate (135x) + 57362: 31, // hintNoHashJoin (135x) + 57369: 32, // hintNoICP (135x) + 57366: 33, // hintNoIndexMerge (135x) + 57364: 34, // hintNoMerge (135x) + 57368: 35, // hintNoMRR (135x) + 57401: 36, // hintNoOrderIndex (135x) + 57370: 37, // hintNoRangeOptimization (135x) + 57374: 38, // hintNoSemijoin (135x) + 57372: 39, // hintNoSkipScan (135x) + 57389: 40, // hintNoSwapJoinInputs (135x) + 57406: 41, // hintNthPlan (135x) + 57400: 42, // hintOrderIndex (135x) 57378: 43, // hintQBName (135x) 57390: 44, // hintQueryType (135x) 57391: 45, // hintReadConsistentReplica (135x) @@ -279,7 +279,6 @@ var ( "hintJoinOrder", "hintJoinPrefix", "hintJoinSuffix", - "hintKeepOrder", "hintLeading", "hintLimitToCop", "hintMaxExecutionTime", @@ -294,14 +293,15 @@ var ( "hintNoHashJoin", "hintNoICP", "hintNoIndexMerge", - "hintNoKeepOrder", "hintNoMerge", "hintNoMRR", + "hintNoOrderIndex", "hintNoRangeOptimization", "hintNoSemijoin", "hintNoSkipScan", "hintNoSwapJoinInputs", "hintNthPlan", + "hintOrderIndex", "hintQBName", "hintQueryType", "hintReadConsistentReplica", @@ -590,7 +590,7 @@ var ( yyhintParseTab = [284][]uint16{ // 0 - {1: 264, 230, 223, 225, 252, 260, 238, 239, 240, 250, 268, 242, 234, 232, 237, 202, 220, 221, 222, 253, 241, 265, 209, 214, 233, 261, 262, 243, 224, 226, 271, 227, 245, 266, 254, 228, 244, 246, 256, 248, 236, 210, 213, 218, 267, 219, 212, 255, 270, 211, 231, 247, 229, 269, 263, 235, 215, 258, 249, 251, 259, 257, 92: 216, 97: 203, 217, 100: 201, 208, 103: 207, 205, 200, 206, 204, 114: 199, 116: 198}, + {1: 264, 230, 223, 225, 252, 260, 238, 239, 240, 250, 268, 242, 234, 232, 237, 202, 220, 221, 222, 241, 265, 209, 214, 233, 261, 262, 243, 224, 226, 271, 227, 245, 266, 228, 244, 254, 246, 256, 248, 236, 210, 253, 213, 218, 267, 219, 212, 255, 270, 211, 231, 247, 229, 269, 263, 235, 215, 258, 249, 251, 259, 257, 92: 216, 97: 203, 217, 100: 201, 208, 103: 207, 205, 200, 206, 204, 114: 199, 116: 198}, {83: 197}, {1: 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 369, 83: 196, 88: 478}, {1: 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 83: 195}, @@ -692,7 +692,7 @@ var ( {1: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 64: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 84: 282, 90: 281}, {63: 375, 78: 374}, // 85 - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 283}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 283}, {159, 63: 159, 78: 159}, {169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 169, 361, 169, 84: 360}, {75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75, 75}, @@ -786,24 +786,24 @@ var ( {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2}, {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}, {165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 78: 165, 80: 364, 99: 373}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 362}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 362}, // 165 {169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 169, 80: 169, 84: 363}, {165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, 78: 165, 80: 364, 99: 365}, {82: 366}, {156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 78: 156}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 368, 115: 367}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 368, 115: 367}, // 170 {370, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 369, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 88: 371}, {163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, 163}, {166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 64: 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 166, 87: 166}, {164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 78: 164}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 372}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 372}, // 175 {162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, 162}, {157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, 78: 157}, {170, 63: 170}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 376}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 376}, {158, 63: 158, 78: 158}, // 180 {1: 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, 83: 173}, @@ -842,10 +842,10 @@ var ( {138}, {1: 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 178, 83: 178}, // 210 - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 408}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 408}, {409, 63: 410}, {1: 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 83: 180}, - {169, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 274, 79: 169, 84: 414, 413, 108: 412, 121: 411}, + {169, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 274, 79: 169, 84: 414, 413, 108: 412, 121: 411}, {416, 79: 417}, // 215 {154, 79: 154}, @@ -854,15 +854,15 @@ var ( {153, 79: 153}, {1: 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 179, 83: 179}, // 220 - {169, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 274, 79: 169, 84: 414, 413, 108: 418}, + {169, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 274, 79: 169, 84: 414, 413, 108: 418}, {155, 79: 155}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 420}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 420}, {421}, {1: 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 83: 181}, // 225 - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 423}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 423}, {81: 424}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 427, 428, 426, 120: 425}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 427, 428, 426, 120: 425}, {429}, {142}, // 230 @@ -896,14 +896,14 @@ var ( {1: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 64: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 84: 452, 93: 451}, {460}, // 255 - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 453}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 453}, {167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 369, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 88: 454}, - {150, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 457, 112: 456, 455}, + {150, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 457, 112: 456, 455}, {151}, {149, 63: 458}, // 260 {148, 63: 148}, - {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 459}, + {1: 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 459}, {147, 63: 147}, {1: 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 186, 83: 186}, {1: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 64: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 84: 452, 93: 462}, @@ -914,7 +914,7 @@ var ( {468}, {161, 63: 375}, // 270 - {160, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 336, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 337, 299, 303, 305, 309, 307, 325, 342, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 283}, + {160, 314, 330, 290, 292, 343, 317, 294, 295, 296, 320, 316, 300, 321, 322, 323, 286, 287, 288, 289, 345, 315, 310, 324, 298, 318, 319, 302, 291, 293, 347, 297, 304, 301, 299, 303, 337, 305, 309, 307, 325, 342, 336, 313, 326, 327, 328, 312, 308, 346, 311, 331, 306, 329, 344, 332, 333, 340, 341, 335, 334, 338, 339, 64: 356, 357, 358, 359, 351, 350, 352, 348, 349, 353, 355, 354, 285, 85: 284, 89: 283}, {1: 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, 83: 188}, {169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 64: 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 274, 84: 467, 90: 466, 96: 470}, {471}, @@ -927,7 +927,7 @@ var ( {477}, // 280 {1: 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 83: 191}, - {1: 264, 230, 223, 225, 252, 260, 238, 239, 240, 250, 268, 242, 234, 232, 237, 202, 220, 221, 222, 253, 241, 265, 209, 214, 233, 261, 262, 243, 224, 226, 271, 227, 245, 266, 254, 228, 244, 246, 256, 248, 236, 210, 213, 218, 267, 219, 212, 255, 270, 211, 231, 247, 229, 269, 263, 235, 215, 258, 249, 251, 259, 257, 92: 216, 97: 203, 217, 100: 480, 208, 103: 207, 205, 479, 206, 204}, + {1: 264, 230, 223, 225, 252, 260, 238, 239, 240, 250, 268, 242, 234, 232, 237, 202, 220, 221, 222, 241, 265, 209, 214, 233, 261, 262, 243, 224, 226, 271, 227, 245, 266, 228, 244, 254, 246, 256, 248, 236, 210, 253, 213, 218, 267, 219, 212, 255, 270, 211, 231, 247, 229, 269, 263, 235, 215, 258, 249, 251, 259, 257, 92: 216, 97: 203, 217, 100: 480, 208, 103: 207, 205, 479, 206, 204}, {1: 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 83: 194}, {1: 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 83: 192}, } diff --git a/parser/hintparser.y b/parser/hintparser.y index 0d92905bb86f3..0a29375be226d 100644 --- a/parser/hintparser.y +++ b/parser/hintparser.y @@ -103,8 +103,8 @@ import ( hintSwapJoinInputs "SWAP_JOIN_INPUTS" hintUseIndexMerge "USE_INDEX_MERGE" hintUseIndex "USE_INDEX" - hintKeepOrder "KEEP_ORDER" - hintNoKeepOrder "NO_KEEP_ORDER" + hintOrderIndex "ORDER_INDEX" + hintNoOrderIndex "NO_ORDER_INDEX" hintUsePlanCache "USE_PLAN_CACHE" hintUseToja "USE_TOJA" hintTimeRange "TIME_RANGE" @@ -609,8 +609,8 @@ SupportedIndexLevelOptimizerHintName: | "IGNORE_INDEX" | "USE_INDEX_MERGE" | "FORCE_INDEX" -| "KEEP_ORDER" -| "NO_KEEP_ORDER" +| "ORDER_INDEX" +| "NO_ORDER_INDEX" SubqueryOptimizerHintName: "SEMIJOIN" @@ -703,8 +703,8 @@ Identifier: | "SWAP_JOIN_INPUTS" | "USE_INDEX_MERGE" | "USE_INDEX" -| "KEEP_ORDER" -| "NO_KEEP_ORDER" +| "ORDER_INDEX" +| "NO_ORDER_INDEX" | "USE_PLAN_CACHE" | "USE_TOJA" | "TIME_RANGE" diff --git a/parser/misc.go b/parser/misc.go index 5e481c24562af..8870ce7a083d0 100644 --- a/parser/misc.go +++ b/parser/misc.go @@ -959,8 +959,8 @@ var hintTokenMap = map[string]int{ "SWAP_JOIN_INPUTS": hintSwapJoinInputs, "USE_INDEX_MERGE": hintUseIndexMerge, "USE_INDEX": hintUseIndex, - "KEEP_ORDER": hintKeepOrder, - "NO_KEEP_ORDER": hintNoKeepOrder, + "ORDER_INDEX": hintOrderIndex, + "NO_ORDER_INDEX": hintNoOrderIndex, "USE_PLAN_CACHE": hintUsePlanCache, "USE_TOJA": hintUseToja, "TIME_RANGE": hintTimeRange, diff --git a/parser/parser_test.go b/parser/parser_test.go index a5dbb70d9cf67..79c62ac27babc 100644 --- a/parser/parser_test.go +++ b/parser/parser_test.go @@ -3899,39 +3899,39 @@ func TestOptimizerHints(t *testing.T) { require.Len(t, hints[1].Indexes, 1) require.Equal(t, "t4", hints[1].Indexes[0].L) - // Test KEEP_ORDER - stmt, _, err = p.Parse("select /*+ KEEP_ORDER(T1,T2), keep_order(t3,t4) */ c1, c2 from t1, t2 where t1.c1 = t2.c1", "", "") + // Test ORDER_INDEX + stmt, _, err = p.Parse("select /*+ ORDER_INDEX(T1,T2), order_index(t3,t4) */ c1, c2 from t1, t2 where t1.c1 = t2.c1", "", "") require.NoError(t, err) selectStmt = stmt[0].(*ast.SelectStmt) hints = selectStmt.TableHints require.Len(t, hints, 2) - require.Equal(t, "keep_order", hints[0].HintName.L) + require.Equal(t, "order_index", hints[0].HintName.L) require.Len(t, hints[0].Tables, 1) require.Equal(t, "t1", hints[0].Tables[0].TableName.L) require.Len(t, hints[0].Indexes, 1) require.Equal(t, "t2", hints[0].Indexes[0].L) - require.Equal(t, "keep_order", hints[1].HintName.L) + require.Equal(t, "order_index", hints[1].HintName.L) require.Len(t, hints[1].Tables, 1) require.Equal(t, "t3", hints[1].Tables[0].TableName.L) require.Len(t, hints[1].Indexes, 1) require.Equal(t, "t4", hints[1].Indexes[0].L) - // Test NO_KEEP_ORDER - stmt, _, err = p.Parse("select /*+ NO_KEEP_ORDER(T1,T2), no_keep_order(t3,t4) */ c1, c2 from t1, t2 where t1.c1 = t2.c1", "", "") + // Test NO_ORDER_INDEX + stmt, _, err = p.Parse("select /*+ NO_ORDER_INDEX(T1,T2), no_order_index(t3,t4) */ c1, c2 from t1, t2 where t1.c1 = t2.c1", "", "") require.NoError(t, err) selectStmt = stmt[0].(*ast.SelectStmt) hints = selectStmt.TableHints require.Len(t, hints, 2) - require.Equal(t, "no_keep_order", hints[0].HintName.L) + require.Equal(t, "no_order_index", hints[0].HintName.L) require.Len(t, hints[0].Tables, 1) require.Equal(t, "t1", hints[0].Tables[0].TableName.L) require.Len(t, hints[0].Indexes, 1) require.Equal(t, "t2", hints[0].Indexes[0].L) - require.Equal(t, "no_keep_order", hints[1].HintName.L) + require.Equal(t, "no_order_index", hints[1].HintName.L) require.Len(t, hints[1].Tables, 1) require.Equal(t, "t3", hints[1].Tables[0].TableName.L) require.Len(t, hints[1].Indexes, 1) diff --git a/planner/core/explain.go b/planner/core/explain.go index ade44533eb360..93d3533bbe3cc 100644 --- a/planner/core/explain.go +++ b/planner/core/explain.go @@ -247,7 +247,13 @@ func (p *PhysicalTableScan) isFullScan() bool { // ExplainInfo implements Plan interface. func (p *PhysicalTableReader) ExplainInfo() string { - return "data:" + p.tablePlan.ExplainID().String() + tablePlanInfo := "data:" + p.tablePlan.ExplainID().String() + + if p.ReadReqType == MPP { + return fmt.Sprintf("MppVersion: %d, %s", p.ctx.GetSessionVars().ChooseMppVersion(), tablePlanInfo) + } + + return tablePlanInfo } // ExplainNormalizedInfo implements Plan interface. @@ -805,6 +811,11 @@ func (p *PhysicalExchangeSender) ExplainInfo() string { fmt.Fprintf(buffer, "Broadcast") case tipb.ExchangeType_Hash: fmt.Fprintf(buffer, "HashPartition") + } + if p.CompressionMode != kv.ExchangeCompressionModeNONE { + fmt.Fprintf(buffer, ", Compression: %s", p.CompressionMode.Name()) + } + if p.ExchangeType == tipb.ExchangeType_Hash { fmt.Fprintf(buffer, ", Hash Cols: %s", property.ExplainColumnList(p.HashCols)) } if len(p.Tasks) > 0 { diff --git a/planner/core/fragment.go b/planner/core/fragment.go index 7595a90bf8f17..1a4f5e6c61f9b 100644 --- a/planner/core/fragment.go +++ b/planner/core/fragment.go @@ -115,11 +115,13 @@ func AllocMPPQueryID() uint64 { } func (e *mppTaskGenerator) generateMPPTasks(s *PhysicalExchangeSender) ([]*Fragment, error) { - logutil.BgLogger().Info("Mpp will generate tasks", zap.String("plan", ToString(s))) + mppVersion := e.ctx.GetSessionVars().ChooseMppVersion() + logutil.BgLogger().Info("Mpp will generate tasks", zap.String("plan", ToString(s)), zap.Int64("mpp-version", mppVersion.ToInt64())) tidbTask := &kv.MPPTask{ StartTs: e.startTS, MppQueryID: e.mppQueryID, ID: -1, + MppVersion: mppVersion, } _, frags, err := e.generateMPPTasksForExchangeSender(s) if err != nil { @@ -157,6 +159,7 @@ func (e *mppTaskGenerator) constructMPPTasksByChildrenTasks(tasks []*kv.MPPTask) MppQueryID: e.mppQueryID, StartTs: e.startTS, TableID: -1, + MppVersion: e.ctx.GetSessionVars().ChooseMppVersion(), } newTasks = append(newTasks, mppTask) addressMap[addr] = struct{}{} @@ -422,6 +425,7 @@ func (e *mppTaskGenerator) constructMPPTasksImpl(ctx context.Context, ts *Physic task := &kv.MPPTask{ Meta: meta, ID: AllocMPPTaskID(e.ctx), + MppVersion: e.ctx.GetSessionVars().ChooseMppVersion(), StartTs: e.startTS, MppQueryID: e.mppQueryID, TableID: ts.Table.ID, diff --git a/planner/core/integration_test.go b/planner/core/integration_test.go index 81da36394968d..39e724ffc6c7a 100644 --- a/planner/core/integration_test.go +++ b/planner/core/integration_test.go @@ -1280,6 +1280,27 @@ func TestIssue15110(t *testing.T) { tk.MustExec("explain format = 'brief' SELECT count(*) FROM crm_rd_150m dataset_48 WHERE (CASE WHEN (month(dataset_48.customer_first_date)) <= 30 THEN '新客' ELSE NULL END) IS NOT NULL;") } +func TestIssue40910(t *testing.T) { + store := testkit.CreateMockStore(t) + tk := testkit.NewTestKit(t, store) + tk.MustExec("use test") + tk.MustExec("drop table if exists t") + tk.MustExec(`create table t(a int, b int, index idx_a(a), index idx_b(b));`) + + tk.MustExec("select * from t where a > 1 and a < 10 order by b;") + tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("0")) + tk.MustExec("create session binding for select * from t where a > 1 and a < 10 order by b using select /*+ use_index(t, idx_a) */ * from t where a > 1 and a < 10 order by b;") + tk.MustExec("select * from t where a > 1 and a < 10 order by b;") + tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("1")) + + tk.MustExec("select /*+ use_index(t, idx_b) */ * from t where a > 1 and a < 10 order by b;") + tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("1")) + + tk.MustExec("select /*+ use_index(t, idx_b) */ * from t where a > 1 and a < 10 order by b;") + tk.MustQuery("show warnings").Check(testkit.Rows( + "Warning 1105 The system ignores the hints in the current query and uses the hints specified in the bindSQL: SELECT /*+ use_index(`t` `idx_a`)*/ * FROM `test`.`t` WHERE `a` > 1 AND `a` < 10 ORDER BY `b`")) +} + func TestReadFromStorageHint(t *testing.T) { store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) @@ -1339,10 +1360,10 @@ func TestKeepOrderHint(t *testing.T) { tk.MustExec("create definer='root'@'localhost' view v1 as select * from t where a<10 order by a limit 1;") // If the optimizer can not generate the keep order plan, it will report error - err := tk.ExecToErr("explain select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 limit 1;") + err := tk.ExecToErr("explain select /*+ order_index(t1, idx_a) */ * from t1 where a<10 limit 1;") require.EqualError(t, err, "[planner:1815]Internal : Can't find a proper physical plan for this query") - err = tk.ExecToErr("explain select /*+ keep_order(t, primary) */ * from t where a<10 limit 1;") + err = tk.ExecToErr("explain select /*+ order_index(t, primary) */ * from t where a<10 limit 1;") require.EqualError(t, err, "[planner:1815]Internal : Can't find a proper physical plan for this query") // The partition table can not keep order @@ -1350,7 +1371,7 @@ func TestKeepOrderHint(t *testing.T) { err = tk.ExecToErr("select a from th where a<1 order by a limit 1;") require.NoError(t, err) - err = tk.ExecToErr("select /*+ keep_order(th, a) */ a from th where a<1 order by a limit 1;") + err = tk.ExecToErr("select /*+ order_index(th, a) */ a from th where a<1 order by a limit 1;") require.EqualError(t, err, "[planner:1815]Internal : Can't find a proper physical plan for this query") var input []string @@ -1382,15 +1403,15 @@ func TestKeepOrderHintWithBinding(t *testing.T) { tk.MustExec("drop table if exists t1") tk.MustExec("create table t1(a int, b int, index idx_a(a));") - // create binding for keep_order hint + // create binding for order_index hint tk.MustExec("select * from t1 where a<10 order by a limit 1;") tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("0")) - tk.MustExec("create global binding for select * from t1 where a<10 order by a limit 1 using select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;") + tk.MustExec("create global binding for select * from t1 where a<10 order by a limit 1 using select /*+ order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;") tk.MustExec("select * from t1 where a<10 order by a limit 1;") tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("1")) res := tk.MustQuery("show global bindings").Rows() require.Equal(t, res[0][0], "select * from `test` . `t1` where `a` < ? order by `a` limit ?") - require.Equal(t, res[0][1], "SELECT /*+ keep_order(`t1` `idx_a`)*/ * FROM `test`.`t1` WHERE `a` < 10 ORDER BY `a` LIMIT 1") + require.Equal(t, res[0][1], "SELECT /*+ order_index(`t1` `idx_a`)*/ * FROM `test`.`t1` WHERE `a` < 10 ORDER BY `a` LIMIT 1") tk.MustExec("drop global binding for select * from t1 where a<10 order by a limit 1;") tk.MustExec("select * from t1 where a<10 order by a limit 1;") @@ -1398,13 +1419,13 @@ func TestKeepOrderHintWithBinding(t *testing.T) { res = tk.MustQuery("show global bindings").Rows() require.Equal(t, len(res), 0) - // create binding for no_keep_order hint - tk.MustExec("create global binding for select * from t1 where a<10 order by a limit 1 using select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;") + // create binding for no_order_index hint + tk.MustExec("create global binding for select * from t1 where a<10 order by a limit 1 using select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;") tk.MustExec("select * from t1 where a<10 order by a limit 1;") tk.MustQuery("select @@last_plan_from_binding").Check(testkit.Rows("1")) res = tk.MustQuery("show global bindings").Rows() require.Equal(t, res[0][0], "select * from `test` . `t1` where `a` < ? order by `a` limit ?") - require.Equal(t, res[0][1], "SELECT /*+ no_keep_order(`t1` `idx_a`)*/ * FROM `test`.`t1` WHERE `a` < 10 ORDER BY `a` LIMIT 1") + require.Equal(t, res[0][1], "SELECT /*+ no_order_index(`t1` `idx_a`)*/ * FROM `test`.`t1` WHERE `a` < 10 ORDER BY `a` LIMIT 1") tk.MustExec("drop global binding for select * from t1 where a<10 order by a limit 1;") tk.MustExec("select * from t1 where a<10 order by a limit 1;") @@ -3026,7 +3047,7 @@ func TestTimeToSecPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "10000.00", "root", " data:ExchangeSender_8"}, + {"TableReader_9", "10000.00", "root", " MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "10000.00", "mpp[tiflash]", " ExchangeType: PassThrough"}, {" └─Projection_4", "10000.00", "mpp[tiflash]", " time_to_sec(test.t.a)->Column#3"}, {" └─TableFullScan_7", "10000.00", "mpp[tiflash]", "table:t", "keep order:false, stats:pseudo"}, @@ -3060,7 +3081,7 @@ func TestRightShiftPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "rightshift(test.t.a, test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -3512,7 +3533,7 @@ func TestReverseUTF8PushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "reverse(test.t.a)->Column#3"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -3546,7 +3567,7 @@ func TestReversePushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "reverse(test.t.a)->Column#3"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -3580,7 +3601,7 @@ func TestSpacePushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "space(test.t.a)->Column#3"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -6782,7 +6803,7 @@ func TestIssue31202(t *testing.T) { tbl.Meta().TiFlashReplica = &model.TiFlashReplicaInfo{Count: 1, Available: true} tk.MustQuery("explain format = 'brief' select * from t31202;").Check(testkit.Rows( - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t31202 keep order:false, stats:pseudo")) @@ -7317,7 +7338,7 @@ func TestRepeatPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "repeat(cast(test.t.a, var_string(20)), test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7346,7 +7367,7 @@ func TestIssue36194(t *testing.T) { } tk.MustQuery("explain format = 'brief' select /*+ read_from_storage(tiflash[t]) */ * from t where a + 1 > 20 limit 100;;").Check(testkit.Rows( "Limit 100.00 root offset:0, count:100", - "└─TableReader 100.00 root data:ExchangeSender", + "└─TableReader 100.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 100.00 mpp[tiflash] ExchangeType: PassThrough", " └─Limit 100.00 mpp[tiflash] offset:0, count:100", " └─Selection 100.00 mpp[tiflash] gt(plus(test.t.a, 1), 20)", @@ -7369,7 +7390,7 @@ func TestGetFormatPushDownToTiFlash(t *testing.T) { tbl.Meta().TiFlashReplica = &model.TiFlashReplicaInfo{Count: 1, Available: true} tk.MustQuery("explain format = 'brief' select GET_FORMAT(DATE, location) from t;").Check(testkit.Rows( - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] get_format(DATE, test.t.location)->Column#3", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo")) @@ -7450,7 +7471,7 @@ func TestLeftShiftPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "leftshift(test.t.a, test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7489,7 +7510,7 @@ func TestHexIntOrStrPushDownToTiFlash(t *testing.T) { tbl.Meta().TiFlashReplica = &model.TiFlashReplicaInfo{Count: 1, Available: true} rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "hex(test.t.a)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7497,7 +7518,7 @@ func TestHexIntOrStrPushDownToTiFlash(t *testing.T) { tk.MustQuery("explain select hex(a) from t;").CheckAt([]int{0, 2, 4}, rows) rows = [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "hex(test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7522,7 +7543,7 @@ func TestBinPushDownToTiFlash(t *testing.T) { tbl.Meta().TiFlashReplica = &model.TiFlashReplicaInfo{Count: 1, Available: true} rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "bin(test.t.a)->Column#3"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7556,7 +7577,7 @@ func TestEltPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "elt(test.t.a, test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7589,7 +7610,7 @@ func TestRegexpInstrPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "regexp_instr(test.t.expr, test.t.pattern, 1, 1, 0, test.t.match_type)->Column#8"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7622,7 +7643,7 @@ func TestRegexpSubstrPushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "regexp_substr(test.t.expr, test.t.pattern, 1, 1, test.t.match_type)->Column#7"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7655,7 +7676,7 @@ func TestRegexpReplacePushDownToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "regexp_replace(test.t.expr, test.t.pattern, test.t.repl, 1, 1, test.t.match_type)->Column#8"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7692,7 +7713,7 @@ func TestCastTimeAsDurationToTiFlash(t *testing.T) { } rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "cast(test.t.a, time BINARY)->Column#4, cast(test.t.b, time BINARY)->Column#5"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7717,7 +7738,7 @@ func TestUnhexPushDownToTiFlash(t *testing.T) { tbl.Meta().TiFlashReplica = &model.TiFlashReplicaInfo{Count: 1, Available: true} rows := [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "unhex(cast(test.t.a, var_string(20)))->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -7725,7 +7746,7 @@ func TestUnhexPushDownToTiFlash(t *testing.T) { tk.MustQuery("explain select unhex(a) from t;").CheckAt([]int{0, 2, 4}, rows) rows = [][]interface{}{ - {"TableReader_9", "root", "data:ExchangeSender_8"}, + {"TableReader_9", "root", "MppVersion: 1, data:ExchangeSender_8"}, {"└─ExchangeSender_8", "mpp[tiflash]", "ExchangeType: PassThrough"}, {" └─Projection_4", "mpp[tiflash]", "unhex(test.t.b)->Column#4"}, {" └─TableFullScan_7", "mpp[tiflash]", "keep order:false, stats:pseudo"}, @@ -8309,6 +8330,54 @@ func TestAutoIncrementCheckWithCheckConstraint(t *testing.T) { )`) } +func TestMppVersion(t *testing.T) { + store, dom := testkit.CreateMockStoreAndDomain(t) + tk := testkit.NewTestKit(t, store) + tk.MustExec("use test") + tk.MustExec("drop table if exists t") + tk.MustExec("create table t(a bigint, b bigint)") + tk.MustExec("set @@tidb_allow_mpp=1; set @@tidb_enforce_mpp=1") + tk.MustExec("set @@tidb_isolation_read_engines = 'tiflash'") + + // Create virtual tiflash replica info. + is := dom.InfoSchema() + db, exists := is.SchemaByName(model.NewCIStr("test")) + require.True(t, exists) + for _, tblInfo := range db.Tables { + if tblInfo.Name.L == "t" { + tblInfo.TiFlashReplica = &model.TiFlashReplicaInfo{ + Count: 1, + Available: true, + } + } + } + + var input []string + var output []struct { + SQL string + Plan []string + Warn []string + } + integrationSuiteData := core.GetIntegrationSuiteData() + integrationSuiteData.LoadTestCases(t, &input, &output) + for i, tt := range input { + setStmt := strings.HasPrefix(tt, "set") + testdata.OnRecord(func() { + output[i].SQL = tt + if !setStmt { + output[i].Plan = testdata.ConvertRowsToStrings(tk.MustQuery(tt).Rows()) + output[i].Warn = testdata.ConvertSQLWarnToStrings(tk.Session().GetSessionVars().StmtCtx.GetWarnings()) + } + }) + if setStmt { + tk.MustExec(tt) + } else { + tk.MustQuery(tt).Check(testkit.Rows(output[i].Plan...)) + require.Equal(t, output[i].Warn, testdata.ConvertSQLWarnToStrings(tk.Session().GetSessionVars().StmtCtx.GetWarnings())) + } + } +} + // https://github.com/pingcap/tidb/issues/36888. func TestIssue36888(t *testing.T) { store := testkit.CreateMockStore(t) diff --git a/planner/core/logical_plan_builder.go b/planner/core/logical_plan_builder.go index f6e566bac43a3..6dbcf6d29548b 100644 --- a/planner/core/logical_plan_builder.go +++ b/planner/core/logical_plan_builder.go @@ -115,10 +115,10 @@ const ( HintIgnoreIndex = "ignore_index" // HintForceIndex make optimizer to use this index even if it thinks a table scan is more efficient. HintForceIndex = "force_index" - // HintKeepOrder is hint enforce using some indexes and keep the index's order. - HintKeepOrder = "keep_order" - // HintNoKeepOrder is hint enforce using some indexes and not keep the index's order. - HintNoKeepOrder = "no_keep_order" + // HintOrderIndex is hint enforce using some indexes and keep the index's order. + HintOrderIndex = "order_index" + // HintNoOrderIndex is hint enforce using some indexes and not keep the index's order. + HintNoOrderIndex = "no_order_index" // HintAggToCop is hint enforce pushing aggregation to coprocessor. HintAggToCop = "agg_to_cop" // HintReadFromStorage is hint enforce some tables read from specific type of storage. @@ -3617,7 +3617,7 @@ func (b *PlanBuilder) pushTableHints(hints []*ast.TableOptimizerHint, currentLev // Set warning for the hint that requires the table name. switch hint.HintName.L { case TiDBMergeJoin, HintSMJ, TiDBIndexNestedLoopJoin, HintINLJ, HintINLHJ, HintINLMJ, - TiDBHashJoin, HintHJ, HintUseIndex, HintIgnoreIndex, HintForceIndex, HintKeepOrder, HintNoKeepOrder, HintIndexMerge, HintLeading: + TiDBHashJoin, HintHJ, HintUseIndex, HintIgnoreIndex, HintForceIndex, HintOrderIndex, HintNoOrderIndex, HintIndexMerge, HintLeading: if len(hint.Tables) == 0 { b.pushHintWithoutTableWarning(hint) continue @@ -3653,7 +3653,7 @@ func (b *PlanBuilder) pushTableHints(hints []*ast.TableOptimizerHint, currentLev aggHints.preferAggType |= preferStreamAgg case HintAggToCop: aggHints.preferAggToCop = true - case HintUseIndex, HintIgnoreIndex, HintForceIndex, HintKeepOrder, HintNoKeepOrder: + case HintUseIndex, HintIgnoreIndex, HintForceIndex, HintOrderIndex, HintNoOrderIndex: dbName := hint.Tables[0].DBName if dbName.L == "" { dbName = model.NewCIStr(b.ctx.GetSessionVars().CurrentDB) @@ -3666,10 +3666,10 @@ func (b *PlanBuilder) pushTableHints(hints []*ast.TableOptimizerHint, currentLev hintType = ast.HintIgnore case HintForceIndex: hintType = ast.HintForce - case HintKeepOrder: - hintType = ast.HintKeepOrder - case HintNoKeepOrder: - hintType = ast.HintNoKeepOrder + case HintOrderIndex: + hintType = ast.HintOrderIndex + case HintNoOrderIndex: + hintType = ast.HintNoOrderIndex } indexHintList = append(indexHintList, indexHintInfo{ dbName: dbName, diff --git a/planner/core/memtable_predicate_extractor.go b/planner/core/memtable_predicate_extractor.go index b4fa83d335a36..07ad325f92163 100644 --- a/planner/core/memtable_predicate_extractor.go +++ b/planner/core/memtable_predicate_extractor.go @@ -210,6 +210,7 @@ func (helper extractHelper) extractCol( for _, expr := range predicates { fn, ok := expr.(*expression.ScalarFunction) if !ok { + remained = append(remained, expr) continue } var colName string diff --git a/planner/core/physical_plans.go b/planner/core/physical_plans.go index 02d01aad5db4c..da0a1e2b0ddf7 100644 --- a/planner/core/physical_plans.go +++ b/planner/core/physical_plans.go @@ -1503,7 +1503,8 @@ type PhysicalExchangeSender struct { ExchangeType tipb.ExchangeType HashCols []*property.MPPPartitionColumn // Tasks is the mpp task for current PhysicalExchangeSender. - Tasks []*kv.MPPTask + Tasks []*kv.MPPTask + CompressionMode kv.ExchangeCompressionMode } // Clone implment PhysicalPlan interface. @@ -1516,6 +1517,7 @@ func (p *PhysicalExchangeSender) Clone() (PhysicalPlan, error) { np.basePhysicalPlan = *base np.ExchangeType = p.ExchangeType np.HashCols = p.HashCols + np.CompressionMode = p.CompressionMode return np, nil } diff --git a/planner/core/plan_cache_test.go b/planner/core/plan_cache_test.go index 9f8ff161fd658..e3a0d276e9815 100644 --- a/planner/core/plan_cache_test.go +++ b/planner/core/plan_cache_test.go @@ -469,6 +469,8 @@ func TestPlanCacheWithLimit(t *testing.T) { params []int }{ {"prepare stmt from 'select * from t limit ?'", []int{1}}, + {"prepare stmt from 'select * from t limit 1, ?'", []int{1}}, + {"prepare stmt from 'select * from t limit ?, 1'", []int{1}}, {"prepare stmt from 'select * from t limit ?, ?'", []int{1, 2}}, {"prepare stmt from 'delete from t order by a limit ?'", []int{1}}, {"prepare stmt from 'insert into t select * from t order by a desc limit ?'", []int{1}}, @@ -491,7 +493,8 @@ func TestPlanCacheWithLimit(t *testing.T) { tk.MustExec("execute stmt using " + strings.Join(using, ", ")) tk.MustQuery("select @@last_plan_from_cache").Check(testkit.Rows("1")) - if idx < 6 { + if idx < 9 { + // none point get plan tk.MustExec("set @a0 = 6") tk.MustExec("execute stmt using " + strings.Join(using, ", ")) tk.MustQuery("select @@last_plan_from_cache").Check(testkit.Rows("0")) diff --git a/planner/core/plan_to_pb.go b/planner/core/plan_to_pb.go index 922b61975ab3c..61edd9471a20c 100644 --- a/planner/core/plan_to_pb.go +++ b/planner/core/plan_to_pb.go @@ -309,6 +309,7 @@ func (e *PhysicalExchangeSender) ToPB(ctx sessionctx.Context, storeType kv.Store Child: child, Types: hashColTypes, AllFieldTypes: allFieldTypes, + Compression: e.CompressionMode.ToTipbCompressionMode(), } executorID := e.ExplainID().String() return &tipb.Executor{ diff --git a/planner/core/planbuilder.go b/planner/core/planbuilder.go index 5535faa97ab92..72e2cc048bf55 100644 --- a/planner/core/planbuilder.go +++ b/planner/core/planbuilder.go @@ -1420,10 +1420,10 @@ func getPossibleAccessPaths(ctx sessionctx.Context, tableHints *tableHintInfo, i // our cost estimation is not reliable. hasUseOrForce = true path.Forced = true - if hint.HintType == ast.HintKeepOrder { + if hint.HintType == ast.HintOrderIndex { path.ForceKeepOrder = true } - if hint.HintType == ast.HintNoKeepOrder { + if hint.HintType == ast.HintNoOrderIndex { path.ForceNoKeepOrder = true } available = append(available, path) diff --git a/planner/core/task.go b/planner/core/task.go index ff4e22756f15a..c0fc7a9bfaad7 100644 --- a/planner/core/task.go +++ b/planner/core/task.go @@ -2243,6 +2243,14 @@ func (t *mppTask) enforceExchangerImpl(prop *property.PhysicalProperty) *mppTask ExchangeType: prop.MPPPartitionTp.ToExchangeType(), HashCols: prop.MPPPartitionCols, }.Init(ctx, t.p.statsInfo()) + + if ctx.GetSessionVars().ChooseMppVersion() >= kv.MppVersionV1 { + // Use compress when exchange type is `Hash` + if sender.ExchangeType == tipb.ExchangeType_Hash { + sender.CompressionMode = ctx.GetSessionVars().ChooseMppExchangeCompressionMode() + } + } + sender.SetChildren(t.p) receiver := PhysicalExchangeReceiver{}.Init(ctx, t.p.statsInfo()) receiver.SetChildren(sender) diff --git a/planner/core/testdata/analyze_suite_out.json b/planner/core/testdata/analyze_suite_out.json index ea1e33b3ca0b8..b10e0b2c69e6a 100644 --- a/planner/core/testdata/analyze_suite_out.json +++ b/planner/core/testdata/analyze_suite_out.json @@ -286,7 +286,7 @@ "Name": "TestTiFlashCostModel", "Cases": [ [ - "TableReader_11 10000.00 root data:ExchangeSender_10", + "TableReader_11 10000.00 root MppVersion: 1, data:ExchangeSender_10", "└─ExchangeSender_10 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan_9 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -298,7 +298,7 @@ "Batch_Point_Get_5 2.00 root table:t handle:[1 2], keep order:false, desc:false" ], [ - "TableReader_10 2.00 root data:ExchangeSender_9", + "TableReader_10 2.00 root MppVersion: 1, data:ExchangeSender_9", "└─ExchangeSender_9 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableRangeScan_8 2.00 mpp[tiflash] table:t range:[1,1], [2,2], keep order:false, stats:pseudo" ] diff --git a/planner/core/testdata/enforce_mpp_suite_out.json b/planner/core/testdata/enforce_mpp_suite_out.json index 91de0d5bd1348..483291bfabd22 100644 --- a/planner/core/testdata/enforce_mpp_suite_out.json +++ b/planner/core/testdata/enforce_mpp_suite_out.json @@ -252,7 +252,7 @@ { "SQL": "explain format = 'brief' SELECT a, ROW_NUMBER() OVER (ORDER BY a) FROM t; -- 5. window unsupported", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window 10000.00 mpp[tiflash] row_number()->Column#7 over(order by test.t.a rows between current row and current row)", " └─Sort 10000.00 mpp[tiflash] test.t.a", @@ -408,7 +408,7 @@ "SQL": "EXPLAIN SELECT count(*) from t group by b; -- 1. new collation FIXME", "Plan": [ "HashAgg_24 8000.00 root group by:test.t.b, funcs:count(Column#7)->Column#4", - "└─TableReader_26 8000.00 root data:ExchangeSender_25", + "└─TableReader_26 8000.00 root MppVersion: 1, data:ExchangeSender_25", " └─ExchangeSender_25 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_11 8000.00 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#7", " └─TableFullScan_21 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -422,7 +422,7 @@ { "SQL": "EXPLAIN SELECT * from t t1 join t t2 on t1.b=t2.b; -- 2. new collation FIXME", "Plan": [ - "TableReader_34 12487.50 root data:ExchangeSender_33", + "TableReader_34 12487.50 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_32 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver_15(Build) 9990.00 mpp[tiflash] ", @@ -546,7 +546,7 @@ { "SQL": "EXPLAIN SELECT * from t join s; -- can use mpp", "Plan": [ - "TableReader_27 100000000.00 root data:ExchangeSender_26", + "TableReader_27 100000000.00 root MppVersion: 1, data:ExchangeSender_26", "└─ExchangeSender_26 100000000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_25 100000000.00 mpp[tiflash] CARTESIAN inner join", " ├─ExchangeReceiver_13(Build) 10000.00 mpp[tiflash] ", @@ -564,7 +564,7 @@ { "SQL": "EXPLAIN SELECT * from t join s; -- can use mpp", "Plan": [ - "TableReader_27 100000000.00 root data:ExchangeSender_26", + "TableReader_27 100000000.00 root MppVersion: 1, data:ExchangeSender_26", "└─ExchangeSender_26 100000000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_25 100000000.00 mpp[tiflash] CARTESIAN inner join", " ├─ExchangeReceiver_13(Build) 10000.00 mpp[tiflash] ", @@ -582,7 +582,7 @@ { "SQL": "explain select a from t where t.a>1 or t.a in (select a from t); -- 7. left outer semi join", "Plan": [ - "TableReader_51 8000.00 root data:ExchangeSender_50", + "TableReader_51 8000.00 root MppVersion: 1, data:ExchangeSender_50", "└─ExchangeSender_50 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] test.t.a", " └─Selection_49 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#3)", @@ -597,7 +597,7 @@ { "SQL": "explain select a from t where t.a>1 or t.a not in (select a from t); -- now it's supported -- 8. anti left outer semi join", "Plan": [ - "TableReader_51 8000.00 root data:ExchangeSender_50", + "TableReader_51 8000.00 root MppVersion: 1, data:ExchangeSender_50", "└─ExchangeSender_50 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] test.t.a", " └─Selection_49 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#3)", @@ -637,7 +637,7 @@ "SQL": "EXPLAIN select count(*) from c, o where c.c_id=o.c_id; -- 1. test agg push down, scalar aggregate", "Plan": [ "HashAgg_13 1.00 root funcs:count(Column#7)->Column#6", - "└─TableReader_35 9990.00 root data:ExchangeSender_34", + "└─TableReader_35 9990.00 root MppVersion: 1, data:ExchangeSender_34", " └─ExchangeSender_34 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_14 9990.00 mpp[tiflash] inner join, equal:[eq(test.c.c_id, test.o.c_id)]", " ├─ExchangeReceiver_33(Build) 8000.00 mpp[tiflash] ", @@ -645,7 +645,7 @@ " │ └─Projection_28 8000.00 mpp[tiflash] Column#7, test.o.c_id", " │ └─HashAgg_29 8000.00 mpp[tiflash] group by:test.o.c_id, funcs:sum(Column#8)->Column#7, funcs:firstrow(test.o.c_id)->test.o.c_id", " │ └─ExchangeReceiver_31 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender_30 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.o.c_id, collate: binary]", + " │ └─ExchangeSender_30 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.o.c_id, collate: binary]", " │ └─HashAgg_20 8000.00 mpp[tiflash] group by:test.o.c_id, funcs:count(1)->Column#8", " │ └─TableFullScan_27 10000.00 mpp[tiflash] table:o keep order:false, stats:pseudo", " └─Selection_18(Probe) 9990.00 mpp[tiflash] not(isnull(test.c.c_id))", @@ -656,20 +656,20 @@ { "SQL": "EXPLAIN select o.o_id, count(*) from c, o where c.c_id=o.c_id group by o.o_id; -- 2. test agg push down, group by non-join column", "Plan": [ - "TableReader_78 8000.00 root data:ExchangeSender_77", + "TableReader_78 8000.00 root MppVersion: 1, data:ExchangeSender_77", "└─ExchangeSender_77 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_10 8000.00 mpp[tiflash] test.o.o_id, Column#6", " └─Projection_76 8000.00 mpp[tiflash] Column#6, test.o.o_id", " └─HashAgg_75 8000.00 mpp[tiflash] group by:test.o.o_id, funcs:count(Column#7)->Column#6, funcs:firstrow(Column#8)->test.o.o_id", " └─ExchangeReceiver_71 9990.00 mpp[tiflash] ", - " └─ExchangeSender_70 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.o.o_id, collate: binary]", + " └─ExchangeSender_70 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.o.o_id, collate: binary]", " └─HashJoin_69 9990.00 mpp[tiflash] inner join, equal:[eq(test.c.c_id, test.o.c_id)]", " ├─ExchangeReceiver_34(Build) 8000.00 mpp[tiflash] ", " │ └─ExchangeSender_33 8000.00 mpp[tiflash] ExchangeType: Broadcast", " │ └─Projection_29 8000.00 mpp[tiflash] Column#7, Column#8, test.o.o_id, test.o.c_id", " │ └─HashAgg_30 8000.00 mpp[tiflash] group by:test.o.c_id, test.o.o_id, funcs:sum(Column#9)->Column#7, funcs:firstrow(test.o.o_id)->Column#8, funcs:firstrow(test.o.o_id)->test.o.o_id, funcs:firstrow(test.o.c_id)->test.o.c_id", " │ └─ExchangeReceiver_32 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender_31 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.o.o_id, collate: binary], [name: test.o.c_id, collate: binary]", + " │ └─ExchangeSender_31 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.o.o_id, collate: binary], [name: test.o.c_id, collate: binary]", " │ └─HashAgg_21 8000.00 mpp[tiflash] group by:test.o.c_id, test.o.o_id, funcs:count(1)->Column#9", " │ └─TableFullScan_28 10000.00 mpp[tiflash] table:o keep order:false, stats:pseudo", " └─Selection_19(Probe) 9990.00 mpp[tiflash] not(isnull(test.c.c_id))", @@ -680,20 +680,20 @@ { "SQL": "EXPLAIN select o.c_id, count(*) from c, o where c.c_id=o.c_id group by o.c_id; -- 3. test agg push down, group by join column", "Plan": [ - "TableReader_78 8000.00 root data:ExchangeSender_77", + "TableReader_78 8000.00 root MppVersion: 1, data:ExchangeSender_77", "└─ExchangeSender_77 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_10 8000.00 mpp[tiflash] test.o.c_id, Column#6", " └─Projection_76 8000.00 mpp[tiflash] Column#6, test.o.c_id", " └─HashAgg_75 8000.00 mpp[tiflash] group by:test.o.c_id, funcs:count(Column#7)->Column#6, funcs:firstrow(Column#8)->test.o.c_id", " └─ExchangeReceiver_71 9990.00 mpp[tiflash] ", - " └─ExchangeSender_70 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.o.c_id, collate: binary]", + " └─ExchangeSender_70 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.o.c_id, collate: binary]", " └─HashJoin_69 9990.00 mpp[tiflash] inner join, equal:[eq(test.c.c_id, test.o.c_id)]", " ├─ExchangeReceiver_34(Build) 8000.00 mpp[tiflash] ", " │ └─ExchangeSender_33 8000.00 mpp[tiflash] ExchangeType: Broadcast", " │ └─Projection_29 8000.00 mpp[tiflash] Column#7, Column#8, test.o.c_id", " │ └─HashAgg_30 8000.00 mpp[tiflash] group by:test.o.c_id, funcs:sum(Column#9)->Column#7, funcs:firstrow(test.o.c_id)->Column#8, funcs:firstrow(test.o.c_id)->test.o.c_id", " │ └─ExchangeReceiver_32 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender_31 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.o.c_id, collate: binary]", + " │ └─ExchangeSender_31 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.o.c_id, collate: binary]", " │ └─HashAgg_21 8000.00 mpp[tiflash] group by:test.o.c_id, funcs:count(1)->Column#9", " │ └─TableFullScan_28 10000.00 mpp[tiflash] table:o keep order:false, stats:pseudo", " └─Selection_19(Probe) 9990.00 mpp[tiflash] not(isnull(test.c.c_id))", @@ -714,17 +714,17 @@ { "SQL": "EXPLAIN select count(distinct c) from t group by d;", "Plan": [ - "TableReader_56 8000.00 root data:ExchangeSender_55", + "TableReader_56 8000.00 root MppVersion: 1, data:ExchangeSender_55", "└─ExchangeSender_55 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_51 8000.00 mpp[tiflash] Column#7", " └─HashAgg_52 8000.00 mpp[tiflash] group by:test.t.d, funcs:sum(Column#18)->Column#7", " └─ExchangeReceiver_54 8000.00 mpp[tiflash] ", - " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary]", + " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary]", " └─HashAgg_50 8000.00 mpp[tiflash] group by:test.t.d, funcs:count(test.t.c)->Column#18", " └─Projection_37 8000.00 mpp[tiflash] test.t.c, test.t.d", " └─HashAgg_38 8000.00 mpp[tiflash] group by:test.t.c, test.t.d, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(test.t.d)->test.t.d", " └─ExchangeReceiver_40 8000.00 mpp[tiflash] ", - " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg_36 8000.00 mpp[tiflash] group by:test.t.c, test.t.d, ", " └─TableFullScan_26 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -733,19 +733,19 @@ { "SQL": "EXPLAIN select count(distinct c), count(a) from t group by d;", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] Column#7, cast(Column#10, bigint(21) BINARY)->Column#8", " └─Projection_52 8000.00 mpp[tiflash] Column#7, Column#10", " └─HashAgg_53 8000.00 mpp[tiflash] group by:test.t.d, funcs:sum(Column#27)->Column#7, funcs:sum(Column#28)->Column#10", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#31, funcs:count(Column#29)->Column#27, funcs:sum(Column#30)->Column#28", " └─Projection_58 8000.00 mpp[tiflash] test.t.c, cast(Column#9, decimal(20,0) BINARY)->Column#30, test.t.d", " └─Projection_38 8000.00 mpp[tiflash] test.t.c, Column#9, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:test.t.c, test.t.d, funcs:firstrow(test.t.c)->test.t.c, funcs:sum(Column#21)->Column#9, funcs:firstrow(test.t.d)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:test.t.c, test.t.d, funcs:count(test.t.a)->Column#21", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -754,18 +754,18 @@ { "SQL": "EXPLAIN select count(distinct c) from t group by b+d;", "Plan": [ - "TableReader_56 8000.00 root data:ExchangeSender_55", + "TableReader_56 8000.00 root MppVersion: 1, data:ExchangeSender_55", "└─ExchangeSender_55 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_51 8000.00 mpp[tiflash] Column#7", " └─HashAgg_52 8000.00 mpp[tiflash] group by:Column#28, funcs:sum(Column#29)->Column#7", " └─ExchangeReceiver_54 8000.00 mpp[tiflash] ", - " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#28, collate: binary]", + " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#28, collate: binary]", " └─HashAgg_50 8000.00 mpp[tiflash] group by:Column#35, funcs:count(Column#34)->Column#29", " └─Projection_58 8000.00 mpp[tiflash] test.t.c, plus(test.t.b, cast(test.t.d, bigint(10) BINARY))->Column#35", " └─Projection_37 8000.00 mpp[tiflash] test.t.c, test.t.b, test.t.d", " └─HashAgg_38 8000.00 mpp[tiflash] group by:Column#20, test.t.c, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(Column#22)->test.t.b, funcs:firstrow(Column#23)->test.t.d", " └─ExchangeReceiver_40 8000.00 mpp[tiflash] ", - " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_36 8000.00 mpp[tiflash] group by:Column#32, Column#33, funcs:firstrow(Column#30)->Column#22, funcs:firstrow(Column#31)->Column#23", " └─Projection_57 10000.00 mpp[tiflash] test.t.b, test.t.d, plus(test.t.b, cast(test.t.d, bigint(10) BINARY))->Column#32, test.t.c", " └─TableFullScan_26 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -775,18 +775,18 @@ { "SQL": "EXPLAIN select count(distinct c) from t group by b+d, a+b;", "Plan": [ - "TableReader_56 8000.00 root data:ExchangeSender_55", + "TableReader_56 8000.00 root MppVersion: 1, data:ExchangeSender_55", "└─ExchangeSender_55 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_51 8000.00 mpp[tiflash] Column#7", " └─HashAgg_52 8000.00 mpp[tiflash] group by:Column#42, Column#43, funcs:sum(Column#44)->Column#7", " └─ExchangeReceiver_54 8000.00 mpp[tiflash] ", - " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#42, collate: binary], [name: Column#43, collate: binary]", + " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#42, collate: binary], [name: Column#43, collate: binary]", " └─HashAgg_50 8000.00 mpp[tiflash] group by:Column#53, Column#54, funcs:count(Column#52)->Column#44", " └─Projection_58 8000.00 mpp[tiflash] test.t.c, plus(test.t.b, cast(test.t.d, bigint(10) BINARY))->Column#53, plus(test.t.a, test.t.b)->Column#54", " └─Projection_37 8000.00 mpp[tiflash] test.t.c, test.t.b, test.t.d, test.t.a, test.t.b", " └─HashAgg_38 8000.00 mpp[tiflash] group by:Column#29, Column#30, test.t.c, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(Column#32)->test.t.b, funcs:firstrow(Column#33)->test.t.d, funcs:firstrow(Column#34)->test.t.a, funcs:firstrow(Column#35)->test.t.b", " └─ExchangeReceiver_40 8000.00 mpp[tiflash] ", - " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_36 8000.00 mpp[tiflash] group by:Column#49, Column#50, Column#51, funcs:firstrow(Column#45)->Column#32, funcs:firstrow(Column#46)->Column#33, funcs:firstrow(Column#47)->Column#34, funcs:firstrow(Column#48)->Column#35", " └─Projection_57 10000.00 mpp[tiflash] test.t.b, test.t.d, test.t.a, test.t.b, plus(test.t.b, cast(test.t.d, bigint(10) BINARY))->Column#49, plus(test.t.a, test.t.b)->Column#50, test.t.c", " └─TableFullScan_26 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -796,19 +796,19 @@ { "SQL": "EXPLAIN select count(distinct c), count(*) from t group by date_format(d,'%Y');", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] Column#7, cast(Column#10, bigint(21) BINARY)->Column#8", " └─Projection_52 8000.00 mpp[tiflash] Column#7, Column#10", " └─HashAgg_53 8000.00 mpp[tiflash] group by:Column#33, funcs:sum(Column#34)->Column#7, funcs:sum(Column#35)->Column#10", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#33, collate: utf8mb4_bin]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#33, collate: utf8mb4_bin]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#41, funcs:count(Column#39)->Column#34, funcs:sum(Column#40)->Column#35", " └─Projection_59 8000.00 mpp[tiflash] test.t.c, cast(Column#9, decimal(20,0) BINARY)->Column#40, date_format(test.t.d, %Y)->Column#41", " └─Projection_38 8000.00 mpp[tiflash] test.t.c, Column#9, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:Column#23, test.t.c, funcs:firstrow(test.t.c)->test.t.c, funcs:sum(Column#25)->Column#9, funcs:firstrow(Column#26)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:Column#37, Column#38, funcs:count(1)->Column#25, funcs:firstrow(Column#36)->Column#26", " └─Projection_58 10000.00 mpp[tiflash] test.t.d, date_format(test.t.d, %Y)->Column#37, test.t.c", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -818,19 +818,19 @@ { "SQL": "EXPLAIN select date_format(d,'%Y') as df, sum(a), count(b), count(distinct c) from t group by date_format(d,'%Y');", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] date_format(test.t.d, %Y)->Column#10, Column#7, cast(Column#14, bigint(21) BINARY)->Column#8, Column#9", " └─Projection_52 8000.00 mpp[tiflash] Column#7, Column#14, Column#9, test.t.d", " └─HashAgg_53 8000.00 mpp[tiflash] group by:Column#45, funcs:sum(Column#46)->Column#7, funcs:sum(Column#47)->Column#14, funcs:sum(Column#48)->Column#9, funcs:firstrow(Column#49)->test.t.d", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#45, collate: utf8mb4_bin]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#45, collate: utf8mb4_bin]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#59, funcs:sum(Column#55)->Column#46, funcs:sum(Column#56)->Column#47, funcs:count(Column#57)->Column#48, funcs:firstrow(Column#58)->Column#49", " └─Projection_59 8000.00 mpp[tiflash] Column#12, cast(Column#13, decimal(20,0) BINARY)->Column#56, test.t.c, test.t.d, date_format(test.t.d, %Y)->Column#59", " └─Projection_38 8000.00 mpp[tiflash] Column#12, Column#13, test.t.c, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:Column#30, test.t.c, funcs:sum(Column#31)->Column#12, funcs:sum(Column#32)->Column#13, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(Column#34)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:Column#53, Column#54, funcs:sum(Column#50)->Column#31, funcs:count(Column#51)->Column#32, funcs:firstrow(Column#52)->Column#34", " └─Projection_58 10000.00 mpp[tiflash] cast(test.t.a, decimal(10,0) BINARY)->Column#50, test.t.b, test.t.d, date_format(test.t.d, %Y)->Column#53, test.t.c", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -840,19 +840,19 @@ { "SQL": "EXPLAIN select d, count(distinct c), sum(a), max(b), count(*) from t group by d;", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] test.t.d, Column#7, Column#8, Column#9, cast(Column#14, bigint(21) BINARY)->Column#10", " └─Projection_52 8000.00 mpp[tiflash] Column#7, Column#8, Column#9, Column#14, test.t.d", " └─HashAgg_53 8000.00 mpp[tiflash] group by:test.t.d, funcs:sum(Column#45)->Column#7, funcs:sum(Column#46)->Column#8, funcs:max(Column#47)->Column#9, funcs:sum(Column#48)->Column#14, funcs:firstrow(test.t.d)->test.t.d", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#58, funcs:count(Column#54)->Column#45, funcs:sum(Column#55)->Column#46, funcs:max(Column#56)->Column#47, funcs:sum(Column#57)->Column#48", " └─Projection_59 8000.00 mpp[tiflash] test.t.c, Column#11, Column#12, cast(Column#13, decimal(20,0) BINARY)->Column#57, test.t.d", " └─Projection_38 8000.00 mpp[tiflash] test.t.c, Column#11, Column#12, Column#13, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:test.t.c, test.t.d, funcs:firstrow(test.t.c)->test.t.c, funcs:sum(Column#31)->Column#11, funcs:max(Column#32)->Column#12, funcs:sum(Column#33)->Column#13, funcs:firstrow(test.t.d)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.d, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:Column#52, Column#53, funcs:sum(Column#50)->Column#31, funcs:max(Column#51)->Column#32, funcs:count(1)->Column#33", " └─Projection_58 10000.00 mpp[tiflash] cast(test.t.a, decimal(10,0) BINARY)->Column#50, test.t.b, test.t.d, test.t.c", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -862,19 +862,19 @@ { "SQL": "EXPLAIN select date_format(d,'%Y') as df, count(distinct c) from t group by date_format(d,'%Y');", "Plan": [ - "TableReader_56 8000.00 root data:ExchangeSender_55", + "TableReader_56 8000.00 root MppVersion: 1, data:ExchangeSender_55", "└─ExchangeSender_55 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_7 8000.00 mpp[tiflash] date_format(test.t.d, %Y)->Column#8, Column#7", " └─Projection_51 8000.00 mpp[tiflash] Column#7, test.t.d", " └─HashAgg_52 8000.00 mpp[tiflash] group by:Column#28, funcs:sum(Column#29)->Column#7, funcs:firstrow(Column#30)->test.t.d", " └─ExchangeReceiver_54 8000.00 mpp[tiflash] ", - " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#28, collate: utf8mb4_bin]", + " └─ExchangeSender_53 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#28, collate: utf8mb4_bin]", " └─HashAgg_50 8000.00 mpp[tiflash] group by:Column#36, funcs:count(Column#34)->Column#29, funcs:firstrow(Column#35)->Column#30", " └─Projection_58 8000.00 mpp[tiflash] test.t.c, test.t.d, date_format(test.t.d, %Y)->Column#36", " └─Projection_37 8000.00 mpp[tiflash] test.t.c, test.t.d", " └─HashAgg_38 8000.00 mpp[tiflash] group by:Column#19, test.t.c, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(Column#21)->test.t.d", " └─ExchangeReceiver_40 8000.00 mpp[tiflash] ", - " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_39 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_36 8000.00 mpp[tiflash] group by:Column#32, Column#33, funcs:firstrow(Column#31)->Column#21", " └─Projection_57 10000.00 mpp[tiflash] test.t.d, date_format(test.t.d, %Y)->Column#32, test.t.c", " └─TableFullScan_26 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -884,19 +884,19 @@ { "SQL": "EXPLAIN select date_format(d,'%Y') as df, a, count(b), count(distinct c) from t group by date_format(d,'%Y'), a;", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] date_format(test.t.d, %Y)->Column#9, test.t.a, cast(Column#12, bigint(21) BINARY)->Column#7, Column#8", " └─Projection_52 8000.00 mpp[tiflash] Column#12, Column#8, test.t.a, test.t.d", " └─HashAgg_53 8000.00 mpp[tiflash] group by:Column#43, test.t.a, funcs:sum(Column#44)->Column#12, funcs:sum(Column#45)->Column#8, funcs:firstrow(test.t.a)->test.t.a, funcs:firstrow(Column#47)->test.t.d", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#56, Column#57, funcs:sum(Column#53)->Column#44, funcs:count(Column#54)->Column#45, funcs:firstrow(Column#55)->Column#47", " └─Projection_59 8000.00 mpp[tiflash] cast(Column#11, decimal(20,0) BINARY)->Column#53, test.t.c, test.t.d, date_format(test.t.d, %Y)->Column#56, test.t.a", " └─Projection_38 8000.00 mpp[tiflash] Column#11, test.t.c, test.t.a, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:Column#28, test.t.a, test.t.c, funcs:sum(Column#29)->Column#11, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(test.t.a)->test.t.a, funcs:firstrow(Column#32)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:Column#50, Column#51, Column#52, funcs:count(Column#48)->Column#29, funcs:firstrow(Column#49)->Column#32", " └─Projection_58 10000.00 mpp[tiflash] test.t.b, test.t.d, date_format(test.t.d, %Y)->Column#50, test.t.a, test.t.c", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -906,19 +906,19 @@ { "SQL": "EXPLAIN select date_format(d,'%Y') as df, a, count(b), avg(distinct c) from t group by date_format(d,'%Y'), a;", "Plan": [ - "TableReader_57 8000.00 root data:ExchangeSender_56", + "TableReader_57 8000.00 root MppVersion: 1, data:ExchangeSender_56", "└─ExchangeSender_56 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_8 8000.00 mpp[tiflash] date_format(test.t.d, %Y)->Column#9, test.t.a, cast(Column#12, bigint(21) BINARY)->Column#7, Column#8", " └─Projection_52 8000.00 mpp[tiflash] Column#12, div(Column#8, cast(case(eq(Column#46, 0), 1, Column#46), decimal(20,0) BINARY))->Column#8, test.t.a, test.t.d", " └─HashAgg_53 8000.00 mpp[tiflash] group by:Column#47, test.t.a, funcs:sum(Column#48)->Column#12, funcs:sum(Column#49)->Column#46, funcs:sum(Column#50)->Column#8, funcs:firstrow(test.t.a)->test.t.a, funcs:firstrow(Column#52)->test.t.d", " └─ExchangeReceiver_55 8000.00 mpp[tiflash] ", - " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender_54 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─HashAgg_51 8000.00 mpp[tiflash] group by:Column#62, Column#63, funcs:sum(Column#58)->Column#48, funcs:count(Column#59)->Column#49, funcs:sum(Column#60)->Column#50, funcs:firstrow(Column#61)->Column#52", " └─Projection_59 8000.00 mpp[tiflash] cast(Column#11, decimal(20,0) BINARY)->Column#58, test.t.c, cast(test.t.c, decimal(20,0) BINARY)->Column#60, test.t.d, date_format(test.t.d, %Y)->Column#62, test.t.a", " └─Projection_38 8000.00 mpp[tiflash] Column#11, test.t.c, test.t.a, test.t.d", " └─HashAgg_39 8000.00 mpp[tiflash] group by:Column#28, test.t.a, test.t.c, funcs:sum(Column#29)->Column#11, funcs:firstrow(test.t.c)->test.t.c, funcs:firstrow(test.t.a)->test.t.a, funcs:firstrow(Column#32)->test.t.d", " └─ExchangeReceiver_41 8000.00 mpp[tiflash] ", - " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender_40 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg_37 8000.00 mpp[tiflash] group by:Column#55, Column#56, Column#57, funcs:count(Column#53)->Column#29, funcs:firstrow(Column#54)->Column#32", " └─Projection_58 10000.00 mpp[tiflash] test.t.b, test.t.d, date_format(test.t.d, %Y)->Column#55, test.t.a, test.t.c", " └─TableFullScan_27 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -955,7 +955,7 @@ { "SQL": "EXPLAIN select count(b), count(distinct c) from t; -- single distinct func but no group key, bail out", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7, Column#8", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#13)->Column#7, funcs:sum(Column#14)->Column#8", @@ -963,7 +963,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#12)->Column#13, funcs:count(distinct test.t.c)->Column#14", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.c, funcs:count(test.t.b)->Column#12", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -982,7 +982,7 @@ { "SQL": "EXPLAIN select count(distinct b) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#9)->Column#7", @@ -990,7 +990,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:count(distinct test.t.b)->Column#9", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.b, ", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -999,7 +999,7 @@ { "SQL": "EXPLAIN select count(distinct c) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#9)->Column#7", @@ -1007,7 +1007,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:count(distinct test.t.c)->Column#9", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.c, ", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -1016,7 +1016,7 @@ { "SQL": "EXPLAIN select count(distinct e) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#9)->Column#7", @@ -1024,7 +1024,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:count(distinct test.t.e)->Column#9", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.e, collate: utf8mb4_general_ci]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.e, collate: utf8mb4_general_ci]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.e, ", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -1033,7 +1033,7 @@ { "SQL": "EXPLAIN select count(distinct a,b,c,e) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#9)->Column#7", @@ -1041,7 +1041,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:count(distinct test.t.a, test.t.b, test.t.c, test.t.e)->Column#9", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary], [name: test.t.c, collate: binary], [name: test.t.e, collate: utf8mb4_general_ci]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary], [name: test.t.c, collate: binary], [name: test.t.e, collate: utf8mb4_general_ci]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.a, test.t.b, test.t.c, test.t.e, ", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -1050,7 +1050,7 @@ { "SQL": "EXPLAIN select count(distinct c), count(a), count(*) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7, Column#8, Column#9", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#17)->Column#7, funcs:sum(Column#18)->Column#8, funcs:sum(Column#19)->Column#9", @@ -1058,7 +1058,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:count(distinct test.t.c)->Column#17, funcs:sum(Column#15)->Column#18, funcs:sum(Column#16)->Column#19", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_26 1.00 mpp[tiflash] group by:test.t.c, funcs:count(test.t.a)->Column#15, funcs:count(1)->Column#16", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -1067,7 +1067,7 @@ { "SQL": "EXPLAIN select sum(b), count(a), count(*), count(distinct c) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7, Column#8, Column#9, Column#10", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#21)->Column#7, funcs:sum(Column#22)->Column#8, funcs:sum(Column#23)->Column#9, funcs:sum(Column#24)->Column#10", @@ -1075,7 +1075,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#18)->Column#21, funcs:sum(Column#19)->Column#22, funcs:sum(Column#20)->Column#23, funcs:count(distinct test.t.c)->Column#24", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_26 1.00 mpp[tiflash] group by:Column#27, funcs:sum(Column#25)->Column#18, funcs:count(Column#26)->Column#19, funcs:count(1)->Column#20", " └─Projection_35 10000.00 mpp[tiflash] cast(test.t.b, decimal(20,0) BINARY)->Column#25, test.t.a, test.t.c", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -1085,7 +1085,7 @@ { "SQL": "EXPLAIN select sum(b+a), count(*), count(distinct c), count(a) from t having count(distinct c) > 2;", "Plan": [ - "TableReader_41 0.80 root data:ExchangeSender_40", + "TableReader_41 0.80 root MppVersion: 1, data:ExchangeSender_40", "└─ExchangeSender_40 0.80 mpp[tiflash] ExchangeType: PassThrough", " └─Selection_39 0.80 mpp[tiflash] gt(Column#9, 2)", " └─Projection_31 1.00 mpp[tiflash] Column#7, Column#8, Column#9, Column#10", @@ -1094,7 +1094,7 @@ " └─ExchangeSender_35 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_32 1.00 mpp[tiflash] funcs:sum(Column#22)->Column#25, funcs:sum(Column#23)->Column#26, funcs:count(distinct test.t.c)->Column#27, funcs:sum(Column#24)->Column#28", " └─ExchangeReceiver_34 1.00 mpp[tiflash] ", - " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_30 1.00 mpp[tiflash] group by:Column#31, funcs:sum(Column#29)->Column#22, funcs:count(1)->Column#23, funcs:count(Column#30)->Column#24", " └─Projection_42 10000.00 mpp[tiflash] cast(plus(test.t.b, test.t.a), decimal(20,0) BINARY)->Column#29, test.t.a, test.t.c", " └─TableFullScan_17 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -1104,7 +1104,7 @@ { "SQL": "EXPLAIN select sum(b+a), count(*), count(a) from t having count(distinct c) > 2;", "Plan": [ - "TableReader_41 0.80 root data:ExchangeSender_40", + "TableReader_41 0.80 root MppVersion: 1, data:ExchangeSender_40", "└─ExchangeSender_40 0.80 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_7 0.80 mpp[tiflash] Column#7, Column#8, Column#9", " └─Selection_39 0.80 mpp[tiflash] gt(Column#10, 2)", @@ -1114,7 +1114,7 @@ " └─ExchangeSender_35 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_32 1.00 mpp[tiflash] funcs:sum(Column#21)->Column#24, funcs:sum(Column#22)->Column#25, funcs:sum(Column#23)->Column#26, funcs:count(distinct test.t.c)->Column#27", " └─ExchangeReceiver_34 1.00 mpp[tiflash] ", - " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_30 1.00 mpp[tiflash] group by:Column#30, funcs:sum(Column#28)->Column#21, funcs:count(1)->Column#22, funcs:count(Column#29)->Column#23", " └─Projection_42 10000.00 mpp[tiflash] cast(plus(test.t.b, test.t.a), decimal(20,0) BINARY)->Column#28, test.t.a, test.t.c", " └─TableFullScan_17 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -1124,7 +1124,7 @@ { "SQL": "EXPLAIN select sum(b+a), max(b), count(distinct c), count(*) from t having count(a) > 2;", "Plan": [ - "TableReader_41 0.80 root data:ExchangeSender_40", + "TableReader_41 0.80 root MppVersion: 1, data:ExchangeSender_40", "└─ExchangeSender_40 0.80 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_7 0.80 mpp[tiflash] Column#7, Column#8, Column#9, Column#10", " └─Selection_39 0.80 mpp[tiflash] gt(Column#11, 2)", @@ -1134,7 +1134,7 @@ " └─ExchangeSender_35 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_32 1.00 mpp[tiflash] funcs:sum(Column#25)->Column#29, funcs:max(Column#26)->Column#30, funcs:count(distinct test.t.c)->Column#31, funcs:sum(Column#27)->Column#32, funcs:sum(Column#28)->Column#33", " └─ExchangeReceiver_34 1.00 mpp[tiflash] ", - " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c, collate: binary]", + " └─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c, collate: binary]", " └─HashAgg_30 1.00 mpp[tiflash] group by:Column#37, funcs:sum(Column#34)->Column#25, funcs:max(Column#35)->Column#26, funcs:count(1)->Column#27, funcs:count(Column#36)->Column#28", " └─Projection_42 10000.00 mpp[tiflash] cast(plus(test.t.b, test.t.a), decimal(20,0) BINARY)->Column#34, test.t.b, test.t.a, test.t.c", " └─TableFullScan_17 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -1144,7 +1144,7 @@ { "SQL": "EXPLAIN select sum(b), count(distinct a, b, e), count(a+b) from t;", "Plan": [ - "TableReader_34 1.00 root data:ExchangeSender_33", + "TableReader_34 1.00 root MppVersion: 1, data:ExchangeSender_33", "└─ExchangeSender_33 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_27 1.00 mpp[tiflash] Column#7, Column#8, Column#9", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#17)->Column#7, funcs:sum(Column#18)->Column#8, funcs:sum(Column#19)->Column#9", @@ -1152,7 +1152,7 @@ " └─ExchangeSender_31 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_28 1.00 mpp[tiflash] funcs:sum(Column#15)->Column#17, funcs:count(distinct test.t.a, test.t.b, test.t.e)->Column#18, funcs:sum(Column#16)->Column#19", " └─ExchangeReceiver_30 1.00 mpp[tiflash] ", - " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary], [name: test.t.e, collate: utf8mb4_general_ci]", + " └─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary], [name: test.t.e, collate: utf8mb4_general_ci]", " └─HashAgg_26 1.00 mpp[tiflash] group by:Column#22, Column#23, Column#24, funcs:sum(Column#20)->Column#15, funcs:count(Column#21)->Column#16", " └─Projection_35 10000.00 mpp[tiflash] cast(test.t.b, decimal(20,0) BINARY)->Column#20, plus(test.t.a, test.t.b)->Column#21, test.t.a, test.t.b, test.t.e", " └─TableFullScan_13 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -1175,7 +1175,7 @@ { "SQL": "EXPLAIN select count(distinct c+a), count(a) from t;", "Plan": [ - "TableReader_30 1.00 root data:ExchangeSender_29", + "TableReader_30 1.00 root MppVersion: 1, data:ExchangeSender_29", "└─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_25 1.00 mpp[tiflash] Column#7, Column#8", " └─HashAgg_26 1.00 mpp[tiflash] funcs:count(distinct Column#11)->Column#7, funcs:sum(Column#12)->Column#8", @@ -1190,7 +1190,7 @@ { "SQL": "EXPLAIN select sum(b), count(distinct c+a, b, e), count(a+b) from t;", "Plan": [ - "TableReader_30 1.00 root data:ExchangeSender_29", + "TableReader_30 1.00 root MppVersion: 1, data:ExchangeSender_29", "└─ExchangeSender_29 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_25 1.00 mpp[tiflash] Column#7, Column#8, Column#9", " └─HashAgg_26 1.00 mpp[tiflash] funcs:sum(Column#13)->Column#7, funcs:count(distinct Column#14, test.t.b, test.t.e)->Column#8, funcs:sum(Column#15)->Column#9", diff --git a/planner/core/testdata/integration_suite_in.json b/planner/core/testdata/integration_suite_in.json index c5185349f0aa2..d475004ffe96b 100644 --- a/planner/core/testdata/integration_suite_in.json +++ b/planner/core/testdata/integration_suite_in.json @@ -656,55 +656,55 @@ { "name": "TestKeepOrderHint", "cases": [ - "explain select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 limit 1;", - "explain select /*+ no_keep_order(t, primary) */ * from t where a<10 limit 1;", + "explain select /*+ order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 limit 1;", + "explain select /*+ no_order_index(t, primary) */ * from t where a<10 limit 1;", // The index doesn't exist - "explain select /*+ keep_order(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", - "explain select /*+ keep_order(t, idx_b) */ * from t where b<10 order by b limit 1;", - "explain select /*+ no_keep_order(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", - "explain select /*+ no_keep_order(t, idx_b) */ * from t where b<10 order by b limit 1;", + "explain select /*+ order_index(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", + "explain select /*+ order_index(t, idx_b) */ * from t where b<10 order by b limit 1;", + "explain select /*+ no_order_index(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", + "explain select /*+ no_order_index(t, idx_b) */ * from t where b<10 order by b limit 1;", - // Use the keep_order/ no_keep_order with the use_index/ ignore_index/ force_index hint at the same time - "explain select /*+ keep_order(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ keep_order(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", - "explain select /*+ keep_order(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ keep_order(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", - "explain select /*+ keep_order(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + // Use the order_index/ no_order_index with the use_index/ ignore_index/ force_index hint at the same time + "explain select /*+ order_index(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ order_index(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", + "explain select /*+ order_index(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ order_index(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", + "explain select /*+ order_index(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", - "explain select /*+ keep_order(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", + "explain select /*+ order_index(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", - "explain select /*+ no_keep_order(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", + "explain select /*+ no_order_index(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", - // Use the keep_order/ no_keep_order with the use_view hint at the same time - "explain select /*+ qb_name(qb, v) keep_order(t1@qb, idx_a) */ * from v", - "explain select /*+ qb_name(qb, v1) keep_order(t@qb, primary) */ * from v1", - "explain select /*+ qb_name(qb, v) no_keep_order(t1@qb, idx_a) */ * from v", - "explain select /*+ qb_name(qb, v1) no_keep_order(t@qb, primary) */ * from v1", + // Use the order_index/ no_order_index with the use_view hint at the same time + "explain select /*+ qb_name(qb, v) order_index(t1@qb, idx_a) */ * from v", + "explain select /*+ qb_name(qb, v1) order_index(t@qb, primary) */ * from v1", + "explain select /*+ qb_name(qb, v) no_order_index(t1@qb, idx_a) */ * from v", + "explain select /*+ qb_name(qb, v1) no_order_index(t@qb, primary) */ * from v1", - // Use the keep_order/ no_keep_order with CTE at the same time - "explain WITH CTE AS (select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", - "explain WITH CTE AS (select /*+ keep_order(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", - "explain WITH CTE AS (select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", - "explain WITH CTE AS (select /*+ no_keep_order(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;" + // Use the order_index/ no_order_index with CTE at the same time + "explain WITH CTE AS (select /*+ order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "explain WITH CTE AS (select /*+ order_index(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "explain WITH CTE AS (select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "explain WITH CTE AS (select /*+ no_order_index(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;" ] }, { @@ -1021,6 +1021,20 @@ "desc format = 'brief' select count(*) from tt group by b1" ] }, + { + "name": "TestMppVersion", + "cases": [ + "desc format = 'brief' select count(*) as cnt from t group by a, b", + "set mpp_exchange_compression_mode = UNSPECIFIED", + "desc format = 'brief' select count(*) as cnt from t group by a, b", + "set mpp_version = 0", + "set mpp_exchange_compression_mode = fast", + "desc format = 'brief' select count(*) as cnt from t group by a, b", + "set mpp_version = -1", + "set mpp_exchange_compression_mode = high_compression", + "desc format = 'brief' select count(*) as cnt from t group by a, b" + ] + }, { "name": "TestPushDownAggForMPP", "cases": [ diff --git a/planner/core/testdata/integration_suite_out.json b/planner/core/testdata/integration_suite_out.json index cb7b47742f619..51f5275c778a0 100644 --- a/planner/core/testdata/integration_suite_out.json +++ b/planner/core/testdata/integration_suite_out.json @@ -2587,7 +2587,7 @@ "SQL": "explain format = 'verbose' select /*+ read_from_storage(tiflash[t1, t2]) */ count(*) from t1 join t2 on t1.a = t2.a", "Plan": [ "StreamAgg_15 1.00 62053.22 root funcs:count(1)->Column#7", - "└─TableReader_41 3.00 61903.52 root data:ExchangeSender_40", + "└─TableReader_41 3.00 61903.52 root MppVersion: 1, data:ExchangeSender_40", " └─ExchangeSender_40 3.00 928447.20 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_37 3.00 928447.20 mpp[tiflash] inner join, equal:[eq(test.t1.a, test.t2.a)]", " ├─ExchangeReceiver_22(Build) 3.00 464290.40 mpp[tiflash] ", @@ -2605,7 +2605,7 @@ "└─HashJoin_59 3.00 71563.94 root inner join, equal:[eq(test.t1.b, test.t3.b)]", " ├─IndexReader_47(Build) 3.00 45.23 root index:IndexFullScan_46", " │ └─IndexFullScan_46 3.00 488.40 cop[tikv] table:t3, index:c(b) keep order:false", - " └─TableReader_39(Probe) 3.00 69652.83 root data:ExchangeSender_38", + " └─TableReader_39(Probe) 3.00 69652.83 root MppVersion: 1, data:ExchangeSender_38", " └─ExchangeSender_38 3.00 1044634.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin_29 3.00 1044634.00 mpp[tiflash] inner join, equal:[eq(test.t1.a, test.t2.a)]", " ├─ExchangeReceiver_35(Build) 3.00 580476.40 mpp[tiflash] ", @@ -2631,7 +2631,7 @@ " │ └─IndexFullScan_25 3.00 610.50 cop[tikv] table:t, index:c(b) keep order:false", " └─Projection_27(Probe) 3.00 43198.32 root 1->Column#26", " └─Limit_30 3.00 43198.22 root offset:0, count:1", - " └─TableReader_37 3.00 43198.22 root data:ExchangeSender_36", + " └─TableReader_37 3.00 43198.22 root MppVersion: 1, data:ExchangeSender_36", " └─ExchangeSender_36 3.00 647920.44 mpp[tiflash] ExchangeType: PassThrough", " └─Limit_35 3.00 647920.44 mpp[tiflash] offset:0, count:1", " └─TableFullScan_34 3.00 647920.44 mpp[tiflash] table:t2 keep order:false" @@ -2952,7 +2952,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t where fact_t.d1_k = d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -2967,7 +2967,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t, d2_t, d3_t where fact_t.d1_k = d1_t.d1_k and fact_t.d2_k = d2_t.d2_k and fact_t.d3_k = d3_t.d3_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#17", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d3_k, test.d3_t.d3_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -2992,7 +2992,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t where fact_t.d1_k = d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3007,7 +3007,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3021,7 +3021,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 8.00 mpp[tiflash] ", @@ -3035,7 +3035,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col1 > d1_t.value", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)], other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3050,7 +3050,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col1 > 10", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], left cond:[gt(test.fact_t.col1, 10)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3064,7 +3064,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col2 > 10 and fact_t.col1 > d1_t.value", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], left cond:[gt(test.fact_t.col2, 10)], other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3078,7 +3078,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k and d1_t.value > 10", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], right cond:gt(test.d1_t.value, 10)", " ├─ExchangeReceiver(Build) 8.00 mpp[tiflash] ", @@ -3092,7 +3092,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k and d1_t.value > 10 and fact_t.col1 > d1_t.value", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], right cond:gt(test.d1_t.value, 10), other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 8.00 mpp[tiflash] ", @@ -3106,7 +3106,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select 1 from d1_t where d1_k = fact_t.d1_k)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3121,7 +3121,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select 1 from d1_t where d1_k = fact_t.d1_k and value > fact_t.col1)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], other cond:gt(test.d1_t.value, test.fact_t.col1)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3136,7 +3136,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select /*+ SEMI_JOIN_REWRITE() */ 1 from d1_t where d1_k = fact_t.d1_k)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 8.00 root data:ExchangeSender", + "└─TableReader 8.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3144,7 +3144,7 @@ " │ └─Projection 2.00 mpp[tiflash] test.d1_t.d1_k", " │ └─HashAgg 2.00 mpp[tiflash] group by:test.d1_t.d1_k, funcs:firstrow(test.d1_t.d1_k)->test.d1_t.d1_k", " │ └─ExchangeReceiver 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 2.00 mpp[tiflash] table:d1_t keep order:false", " └─Selection(Probe) 8.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", @@ -3155,7 +3155,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select /*+ SEMI_JOIN_REWRITE() */ 1 from d1_t where d1_k = fact_t.d1_k and value > fact_t.col1)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], other cond:gt(test.d1_t.value, test.fact_t.col1)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3170,7 +3170,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where not exists (select 1 from d1_t where d1_k = fact_t.d1_k)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] anti semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3183,7 +3183,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where not exists (select 1 from d1_t where d1_k = fact_t.d1_k and value > fact_t.col1)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] anti semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], other cond:gt(test.d1_t.value, test.fact_t.col1)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3196,7 +3196,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t join d1_t on fact_t.d1_k > d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 16.00 root data:ExchangeSender", + "└─TableReader 16.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 16.00 mpp[tiflash] CARTESIAN inner join, other cond:gt(test.fact_t.d1_k, test.d1_t.d1_k)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3211,7 +3211,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k > d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 16.00 root data:ExchangeSender", + "└─TableReader 16.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 16.00 mpp[tiflash] CARTESIAN left outer join, other cond:gt(test.fact_t.d1_k, test.d1_t.d1_k)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3225,7 +3225,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k > d1_t.d1_k", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 16.00 root data:ExchangeSender", + "└─TableReader 16.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 16.00 mpp[tiflash] CARTESIAN right outer join, other cond:gt(test.fact_t.d1_k, test.d1_t.d1_k)", " ├─ExchangeReceiver(Build) 8.00 mpp[tiflash] ", @@ -3239,7 +3239,7 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where d1_k not in (select d1_k from d1_t)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#11", - "└─TableReader 6.40 root data:ExchangeSender", + "└─TableReader 6.40 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6.40 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6.40 mpp[tiflash] CARTESIAN anti semi join, other cond:eq(test.fact_t.d1_k, test.d1_t.d1_k)", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -3256,7 +3256,7 @@ { "SQL": "explain format = 'brief' select * from test.t t1 where t1.a>1 or t1.a in (select a from test.t); -- left semi", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, test.t.b", " └─Selection 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#7)", @@ -3271,7 +3271,7 @@ { "SQL": "explain format = 'brief' select * from test.t t1 where t1.a>1 or t1.a in (select a from test.t where b1 or t1.a not in (select a from test.t); -- left anti", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, test.t.b", " └─Selection 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#7)", @@ -3301,7 +3301,7 @@ { "SQL": "explain format = 'brief' select * from test.t t1 where t1.a>1 or t1.a not in (select a from test.t where b1 or t1.b in (select a from test.t); -- cartesian left semi", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, test.t.b", " └─Selection 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#7)", @@ -3331,7 +3331,7 @@ { "SQL": "explain format = 'brief' select * from test.t t1 where t1.a>1 or t1.a in (select b from test.t where b1 or t1.b not in (select a from test.t); -- cartesian left anti", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, test.t.b", " └─Selection 8000.00 mpp[tiflash] or(gt(test.t.a, 1), Column#7)", @@ -3361,7 +3361,7 @@ { "SQL": "explain format = 'brief' select * from test.t t1 where t1.a>1 or t1.b not in (select a from test.t where bColumn#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] left outer join, equal:[eq(test.a.id, test.b.id)]", " ├─ExchangeReceiver(Build) 3.00 mpp[tiflash] ", @@ -3509,7 +3509,7 @@ "SQL": "explain format = 'brief' select count(*) from b right join a on a.id = b.id", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] right outer join, equal:[eq(test.b.id, test.a.id)]", " ├─ExchangeReceiver(Build) 3.00 mpp[tiflash] ", @@ -3528,15 +3528,15 @@ "SQL": "explain format = 'brief' select count(*) from a left join b on a.id = b.id", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] left outer join, equal:[eq(test.a.id, test.b.id)]", " ├─ExchangeReceiver(Build) 3.00 mpp[tiflash] ", - " │ └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.b.id, collate: binary]", + " │ └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.b.id, collate: binary]", " │ └─Selection 3.00 mpp[tiflash] not(isnull(test.b.id))", " │ └─TableFullScan 3.00 mpp[tiflash] table:b keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.a.id, collate: binary]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.a.id, collate: binary]", " └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false" ] }, @@ -3544,15 +3544,15 @@ "SQL": "explain format = 'brief' select count(*) from b right join a on a.id = b.id", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] right outer join, equal:[eq(test.b.id, test.a.id)]", " ├─ExchangeReceiver(Build) 3.00 mpp[tiflash] ", - " │ └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.b.id, collate: binary]", + " │ └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.b.id, collate: binary]", " │ └─Selection 3.00 mpp[tiflash] not(isnull(test.b.id))", " │ └─TableFullScan 3.00 mpp[tiflash] table:b keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.a.id, collate: binary]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.a.id, collate: binary]", " └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false" ] } @@ -3565,14 +3565,14 @@ "SQL": "explain format = 'brief' select count(*) from a left join b on a.id = b.id", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] left outer join, equal:[eq(test.a.id, test.b.id)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.a.id, collate: binary]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.a.id, collate: binary]", " │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " └─ExchangeReceiver(Probe) 3.00 mpp[tiflash] ", - " └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.b.id, collate: binary]", + " └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.b.id, collate: binary]", " └─Selection 3.00 mpp[tiflash] not(isnull(test.b.id))", " └─TableFullScan 3.00 mpp[tiflash] table:b keep order:false" ] @@ -3581,14 +3581,14 @@ "SQL": "explain format = 'brief' select count(*) from b right join a on a.id = b.id", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#7", - "└─TableReader 2.00 root data:ExchangeSender", + "└─TableReader 2.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] right outer join, equal:[eq(test.b.id, test.a.id)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.a.id, collate: binary]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.a.id, collate: binary]", " │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " └─ExchangeReceiver(Probe) 3.00 mpp[tiflash] ", - " └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.b.id, collate: binary]", + " └─ExchangeSender 3.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.b.id, collate: binary]", " └─Selection 3.00 mpp[tiflash] not(isnull(test.b.id))", " └─TableFullScan 3.00 mpp[tiflash] table:b keep order:false" ] @@ -3602,16 +3602,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t where fact_t.d1_k = d1_t.d1_k", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3620,30 +3620,30 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t, d2_t, d3_t where fact_t.d1_k = d1_t.d1_k and fact_t.d2_k = d2_t.d2_k and fact_t.d3_k = d3_t.d3_k", "Plan": [ "HashAgg 1.00 root funcs:count(Column#18)->Column#17", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#18", " └─HashJoin 128.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d3_k, test.d3_t.d3_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d3_t.d3_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d3_t.d3_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d3_t.d3_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d3_t keep order:false", " └─ExchangeReceiver(Probe) 64.00 mpp[tiflash] ", - " └─ExchangeSender 64.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d3_k, collate: binary]", + " └─ExchangeSender 64.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d3_k, collate: binary]", " └─HashJoin 64.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d2_k, test.d2_t.d2_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d2_t.d2_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d2_t.d2_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d2_t.d2_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d2_t keep order:false", " └─ExchangeReceiver(Probe) 32.00 mpp[tiflash] ", - " └─ExchangeSender 32.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d2_k, collate: binary]", + " └─ExchangeSender 32.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d2_k, collate: binary]", " └─HashJoin 32.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k)), not(isnull(test.fact_t.d2_k)), not(isnull(test.fact_t.d3_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3652,16 +3652,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t where fact_t.d1_k = d1_t.d1_k", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3670,26 +3670,26 @@ "SQL": "explain format = 'brief' select count(*) from fact_t, d1_t, d2_t, d3_t where fact_t.d1_k = d1_t.d1_k and fact_t.d1_k = d2_t.value and fact_t.d1_k = d3_t.value", "Plan": [ "HashAgg 1.00 root funcs:count(Column#18)->Column#17", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#18", " └─HashJoin 128.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d1_k, test.d3_t.value)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d3_t.value, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d3_t.value, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d3_t.value))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d3_t keep order:false", " └─HashJoin(Probe) 64.00 mpp[tiflash] inner join, equal:[eq(test.fact_t.d1_k, test.d2_t.value)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d2_t.value, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d2_t.value, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d2_t.value))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d2_t keep order:false", " └─HashJoin(Probe) 32.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3698,16 +3698,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] }, @@ -3715,15 +3715,15 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3732,16 +3732,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col1 > d1_t.value", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)], other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k)), not(isnull(test.d1_t.value))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.col1)), not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3750,16 +3750,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col1 > 10", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], left cond:[gt(test.fact_t.col1, 10)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] }, @@ -3767,23 +3767,23 @@ "SQL": "explain format = 'brief' select count(*) from (select case when t1.col1 is null then t2.col1 + 5 else 10 end as col1, t2.d1_k as d1_k from fact_t t1 right join fact_t t2 on t1.d1_k = t2.d1_k) fact_t join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col1 > 5", "Plan": [ "HashAgg 1.00 root funcs:count(Column#22)->Column#19", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#22", " └─HashJoin 204.80 mpp[tiflash] inner join, equal:[eq(test.d1_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─Projection(Probe) 102.40 mpp[tiflash] test.fact_t.d1_k", " └─Selection 102.40 mpp[tiflash] gt(case(isnull(test.fact_t.col1), plus(test.fact_t.col1, 5), 10), 5)", " └─HashJoin 128.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.fact_t.d1_k)]", " ├─ExchangeReceiver(Build) 16.00 mpp[tiflash] ", - " │ └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " │ └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " │ └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " │ └─TableFullScan 16.00 mpp[tiflash] table:t1 keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:t2 keep order:false" ] @@ -3792,16 +3792,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t left join d1_t on fact_t.d1_k = d1_t.d1_k and fact_t.col2 > 10 and fact_t.col1 > d1_t.value", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] left outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], left cond:[gt(test.fact_t.col2, 10)], other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k)), not(isnull(test.d1_t.value))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] }, @@ -3809,15 +3809,15 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k and d1_t.value > 10", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], right cond:gt(test.d1_t.value, 10)", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3826,16 +3826,16 @@ "SQL": "explain format = 'brief' select count(*) from fact_t right join d1_t on fact_t.d1_k = d1_t.d1_k and d1_t.value > 10 and fact_t.col1 > d1_t.value", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─HashJoin 32.00 mpp[tiflash] right outer join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], right cond:gt(test.d1_t.value, 10), other cond:gt(test.fact_t.col1, test.d1_t.value)", " ├─ExchangeReceiver(Build) 16.00 mpp[tiflash] ", - " │ └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " │ └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " │ └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.col1)), not(isnull(test.fact_t.d1_k))", " │ └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false", " └─ExchangeReceiver(Probe) 4.00 mpp[tiflash] ", - " └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false" ] }, @@ -3843,15 +3843,15 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select 1 from d1_t where d1_k = fact_t.d1_k)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 12.80 root data:ExchangeSender", + "└─TableReader 12.80 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12.80 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12.80 mpp[tiflash] semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3860,15 +3860,15 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where exists (select 1 from d1_t where d1_k = fact_t.d1_k and value > fact_t.col1)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 12.80 root data:ExchangeSender", + "└─TableReader 12.80 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12.80 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12.80 mpp[tiflash] semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], other cond:gt(test.d1_t.value, test.fact_t.col1)", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─Selection 4.00 mpp[tiflash] not(isnull(test.d1_t.d1_k)), not(isnull(test.d1_t.value))", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─Selection 16.00 mpp[tiflash] not(isnull(test.fact_t.col1)), not(isnull(test.fact_t.d1_k))", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] @@ -3877,14 +3877,14 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where not exists (select 1 from d1_t where d1_k = fact_t.d1_k)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 12.80 root data:ExchangeSender", + "└─TableReader 12.80 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12.80 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12.80 mpp[tiflash] anti semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)]", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] }, @@ -3892,14 +3892,14 @@ "SQL": "explain format = 'brief' select count(*) from fact_t where not exists (select 1 from d1_t where d1_k = fact_t.d1_k and value > fact_t.col1)", "Plan": [ "StreamAgg 1.00 root funcs:count(1)->Column#12", - "└─TableReader 12.80 root data:ExchangeSender", + "└─TableReader 12.80 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12.80 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12.80 mpp[tiflash] anti semi join, equal:[eq(test.fact_t.d1_k, test.d1_t.d1_k)], other cond:gt(test.d1_t.value, test.fact_t.col1)", " ├─ExchangeReceiver(Build) 4.00 mpp[tiflash] ", - " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", + " │ └─ExchangeSender 4.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.d1_t.d1_k, collate: binary]", " │ └─TableFullScan 4.00 mpp[tiflash] table:d1_t keep order:false", " └─ExchangeReceiver(Probe) 16.00 mpp[tiflash] ", - " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", + " └─ExchangeSender 16.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.fact_t.d1_k, collate: binary]", " └─TableFullScan 16.00 mpp[tiflash] table:fact_t keep order:false" ] } @@ -3911,22 +3911,22 @@ { "SQL": "explain format = 'brief' select v from t3 as a left join (select t1.v1, t1.v2, t1.v1 + t1.v2 as v from t1 left join t2 on t1.v1 = t2.v1 and t1.v2 = t2.v2) b on a.v1 = b.v1 and a.v2 = b.v2", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#13", " └─HashJoin 1.00 mpp[tiflash] left outer join, equal:[eq(test.t3.v1, test.t1.v1) eq(test.t3.v2, test.t1.v2)]", " ├─ExchangeReceiver(Build) 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#23, collate: binary], [name: Column#24, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#23, collate: binary], [name: Column#24, collate: binary]", " │ └─Projection 1.00 mpp[tiflash] test.t3.v1, test.t3.v2, cast(test.t3.v1, decimal(20,2))->Column#23, cast(test.t3.v2, decimal(20,2))->Column#24", " │ └─TableFullScan 1.00 mpp[tiflash] table:a keep order:false", " └─Projection(Probe) 2.00 mpp[tiflash] test.t1.v1, test.t1.v2, plus(test.t1.v1, test.t1.v2)->Column#13", " └─HashJoin 2.00 mpp[tiflash] left outer join, equal:[eq(test.t1.v1, test.t2.v1) eq(test.t1.v2, test.t2.v2)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.v1, collate: binary], [name: test.t1.v2, collate: binary]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.v1, collate: binary], [name: test.t1.v2, collate: binary]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.t1.v1)), not(isnull(test.t1.v2))", " │ └─TableFullScan 2.00 mpp[tiflash] table:t1 keep order:false", " └─ExchangeReceiver(Probe) 8.00 mpp[tiflash] ", - " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#15, collate: binary], [name: Column#16, collate: binary]", + " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#15, collate: binary], [name: Column#16, collate: binary]", " └─Projection 8.00 mpp[tiflash] test.t2.v1, test.t2.v2, cast(test.t2.v1, decimal(20,2))->Column#15, cast(test.t2.v2, decimal(20,2))->Column#16", " └─Selection 8.00 mpp[tiflash] not(isnull(test.t2.v1)), not(isnull(test.t2.v2))", " └─TableFullScan 8.00 mpp[tiflash] table:t2 keep order:false" @@ -3935,19 +3935,19 @@ { "SQL": "explain format = 'brief' select count(*), t2.v1, t2.v2 from t1 left join t2 on t1.v1 = t2.v1 and t1.v2 = t2.v2 group by t2.v1, t2.v2", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2.00 mpp[tiflash] Column#9, test.t2.v1, test.t2.v2", " └─HashAgg 2.00 mpp[tiflash] group by:test.t2.v1, test.t2.v2, funcs:sum(Column#22)->Column#9, funcs:firstrow(test.t2.v1)->test.t2.v1, funcs:firstrow(test.t2.v2)->test.t2.v2", " └─ExchangeReceiver 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", " └─HashAgg 2.00 mpp[tiflash] group by:test.t2.v1, test.t2.v2, funcs:count(1)->Column#22", " └─HashJoin 2.00 mpp[tiflash] left outer join, equal:[eq(test.t1.v1, test.t2.v1) eq(test.t1.v2, test.t2.v2)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.v1, collate: binary], [name: test.t1.v2, collate: binary]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.v1, collate: binary], [name: test.t1.v2, collate: binary]", " │ └─TableFullScan 2.00 mpp[tiflash] table:t1 keep order:false", " └─ExchangeReceiver(Probe) 8.00 mpp[tiflash] ", - " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#14, collate: binary], [name: Column#15, collate: binary]", + " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#14, collate: binary], [name: Column#15, collate: binary]", " └─Projection 8.00 mpp[tiflash] test.t2.v1, test.t2.v2, cast(test.t2.v1, decimal(20,2))->Column#14, cast(test.t2.v2, decimal(20,2))->Column#15", " └─Selection 8.00 mpp[tiflash] not(isnull(test.t2.v1)), not(isnull(test.t2.v2))", " └─TableFullScan 8.00 mpp[tiflash] table:t2 keep order:false" @@ -3956,18 +3956,18 @@ { "SQL": "explain format = 'brief' select count(*), t2.v1, t2.v2 from t3 left join t2 on t3.v1 = t2.v1 and t3.v2 = t2.v2 group by t2.v1, t2.v2", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#9, test.t2.v1, test.t2.v2", " └─HashAgg 1.00 mpp[tiflash] group by:test.t2.v1, test.t2.v2, funcs:count(1)->Column#9, funcs:firstrow(test.t2.v1)->test.t2.v1, funcs:firstrow(test.t2.v2)->test.t2.v2", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", " └─HashJoin 1.00 mpp[tiflash] left outer join, equal:[eq(test.t3.v1, test.t2.v1) eq(test.t3.v2, test.t2.v2)]", " ├─ExchangeReceiver(Build) 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t3.v1, collate: binary], [name: test.t3.v2, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t3.v1, collate: binary], [name: test.t3.v2, collate: binary]", " │ └─TableFullScan 1.00 mpp[tiflash] table:t3 keep order:false", " └─ExchangeReceiver(Probe) 8.00 mpp[tiflash] ", - " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", + " └─ExchangeSender 8.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.v1, collate: binary], [name: test.t2.v2, collate: binary]", " └─Selection 8.00 mpp[tiflash] not(isnull(test.t2.v1)), not(isnull(test.t2.v2))", " └─TableFullScan 8.00 mpp[tiflash] table:t2 keep order:false" ] @@ -4025,15 +4025,15 @@ { "SQL": "explain format = 'brief' select * from table_1 a, table_1 b where a.value = b.value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_1.value)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", " └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " └─TableFullScan 2.00 mpp[tiflash] table:b keep order:false" ] @@ -4041,15 +4041,15 @@ { "SQL": "explain format = 'brief' select * from table_1 a, table_2 b where a.value = b.value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_2.value)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", " └─Selection 2.00 mpp[tiflash] not(isnull(test.table_2.value))", " └─TableFullScan 2.00 mpp[tiflash] table:b keep order:false" ] @@ -4057,20 +4057,20 @@ { "SQL": "explain format = 'brief' select * from table_1 a, table_2 b, table_1 c where a.value = b.value and b.value = c.value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_2.value, test.table_1.value)]", " ├─HashJoin(Build) 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_2.value)]", " │ ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", + " │ │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", " │ │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " │ │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " │ └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_2.value))", " │ └─TableFullScan 2.00 mpp[tiflash] table:b keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", " └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " └─TableFullScan 2.00 mpp[tiflash] table:c keep order:false" ] @@ -4078,22 +4078,22 @@ { "SQL": "explain format = 'brief' select * from table_1 a, table_2 b, table_1 c where a.value = b.value and a.value = c.value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_1.value)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", " │ └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_2.value)]", " │ ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", - " │ │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", + " │ │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_bin]", " │ │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " │ │ └─TableFullScan 2.00 mpp[tiflash] table:a keep order:false", " │ └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", + " │ └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", " │ └─Selection 2.00 mpp[tiflash] not(isnull(test.table_2.value))", " │ └─TableFullScan 2.00 mpp[tiflash] table:b keep order:false", " └─ExchangeReceiver(Probe) 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", " └─Selection 2.00 mpp[tiflash] not(isnull(test.table_1.value))", " └─TableFullScan 2.00 mpp[tiflash] table:c keep order:false" ] @@ -4101,24 +4101,24 @@ { "SQL": "explain format = 'brief' select /*+ agg_to_cop() */ count(*), value from table_1 group by value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2.00 mpp[tiflash] Column#4, test.table_1.value", " └─HashAgg 2.00 mpp[tiflash] group by:test.table_1.value, funcs:count(1)->Column#4, funcs:firstrow(test.table_1.value)->test.table_1.value", " └─ExchangeReceiver 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.value, collate: utf8mb4_general_ci]", " └─TableFullScan 2.00 mpp[tiflash] table:table_1 keep order:false" ] }, { "SQL": "explain format = 'brief' select /*+ agg_to_cop() */ count(*), value from table_2 group by value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2.00 mpp[tiflash] Column#4, test.table_2.value", " └─HashAgg 2.00 mpp[tiflash] group by:test.table_2.value, funcs:count(1)->Column#4, funcs:firstrow(test.table_2.value)->test.table_2.value", " └─ExchangeReceiver 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_2.value, collate: utf8mb4_bin]", " └─TableFullScan 2.00 mpp[tiflash] table:table_2 keep order:false" ] } @@ -4130,7 +4130,7 @@ { "SQL": "explain format = 'brief' select /*+ broadcast_join(a,b) */ * from table_1 a, table_1 b where a.id = b.id", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.id, test.table_1.id)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -4142,7 +4142,7 @@ { "SQL": "explain format = 'brief' select /*+ broadcast_join(a,b) */ * from table_1 a, table_1 b where a.value = b.value", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 2.00 mpp[tiflash] inner join, equal:[eq(test.table_1.value, test.table_1.value)]", " ├─ExchangeReceiver(Build) 2.00 mpp[tiflash] ", @@ -4161,14 +4161,14 @@ { "SQL": "explain format = 'brief' select /*+ avg_to_cop() */ id, avg(value+1),avg(value) from table_1 group by id", "Plan": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2.00 mpp[tiflash] test.table_1.id, Column#4, Column#5", " └─Projection 2.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#25, 0), 1, Column#25), decimal(20,0) BINARY))->Column#4, div(Column#5, cast(case(eq(Column#26, 0), 1, Column#26), decimal(20,0) BINARY))->Column#5, test.table_1.id", " └─HashAgg 2.00 mpp[tiflash] group by:Column#39, funcs:count(Column#34)->Column#25, funcs:sum(Column#35)->Column#4, funcs:count(Column#36)->Column#26, funcs:sum(Column#37)->Column#5, funcs:firstrow(Column#38)->test.table_1.id", " └─Projection 2.00 mpp[tiflash] plus(test.table_1.value, 1)->Column#34, plus(test.table_1.value, 1)->Column#35, test.table_1.value, test.table_1.value, test.table_1.id, test.table_1.id", " └─ExchangeReceiver 2.00 mpp[tiflash] ", - " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.table_1.id, collate: binary]", + " └─ExchangeSender 2.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.table_1.id, collate: binary]", " └─TableFullScan 2.00 mpp[tiflash] table:table_1 keep order:false" ] } @@ -4325,7 +4325,7 @@ "Name": "TestKeepOrderHint", "Cases": [ { - "SQL": "explain select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "Limit_12 1.00 root offset:0, count:1", "└─Projection_17 1.00 root test.t1.a, test.t1.b", @@ -4337,7 +4337,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_15 1.00 root data:Limit_14", @@ -4347,7 +4347,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "TopN_9 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_16 1.00 root ", @@ -4358,7 +4358,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_15 1.00 root data:TopN_14", @@ -4368,7 +4368,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 limit 1;", "Plan": [ "IndexLookUp_13 1.00 root limit embedded(offset:0, count:1)", "├─Limit_12(Build) 1.00 cop[tikv] offset:0, count:1", @@ -4378,7 +4378,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) */ * from t where a<10 limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) */ * from t where a<10 limit 1;", "Plan": [ "Limit_8 1.00 root offset:0, count:1", "└─TableReader_12 1.00 root data:Limit_11", @@ -4388,7 +4388,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", "Plan": [ "TopN_8 1.00 root test.t1.b, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4401,7 +4401,7 @@ ] }, { - "SQL": "explain select /*+ keep_order(t, idx_b) */ * from t where b<10 order by b limit 1;", + "SQL": "explain select /*+ order_index(t, idx_b) */ * from t where b<10 order by b limit 1;", "Plan": [ "TopN_8 1.00 root test.t.b, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4414,7 +4414,7 @@ ] }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_b) */ * from t1 where b<10 order by b limit 1;", "Plan": [ "TopN_8 1.00 root test.t1.b, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4427,7 +4427,7 @@ ] }, { - "SQL": "explain select /*+ no_keep_order(t, idx_b) */ * from t where b<10 order by b limit 1;", + "SQL": "explain select /*+ no_order_index(t, idx_b) */ * from t where b<10 order by b limit 1;", "Plan": [ "TopN_8 1.00 root test.t.b, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4440,7 +4440,7 @@ ] }, { - "SQL": "explain select /*+ keep_order(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "Limit_12 1.00 root offset:0, count:1", "└─Projection_19 1.00 root test.t1.a, test.t1.b", @@ -4452,7 +4452,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", "Plan": [ "Limit_12 1.00 root offset:0, count:1", "└─Projection_19 1.00 root test.t1.a, test.t1.b", @@ -4464,7 +4464,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "Limit_12 1.00 root offset:0, count:1", "└─Projection_19 1.00 root test.t1.a, test.t1.b", @@ -4476,7 +4476,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", "Plan": [ "Limit_12 1.00 root offset:0, count:1", "└─Projection_19 1.00 root test.t1.a, test.t1.b", @@ -4488,7 +4488,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t1.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4499,7 +4499,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_16 1.00 root data:Limit_15", @@ -4509,7 +4509,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_16 1.00 root data:Limit_15", @@ -4519,7 +4519,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_16 1.00 root data:Limit_15", @@ -4529,7 +4529,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_16 1.00 root data:Limit_15", @@ -4539,7 +4539,7 @@ "Warn": null }, { - "SQL": "explain select /*+ keep_order(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ order_index(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "Limit_11 1.00 root offset:0, count:1", "└─TableReader_15 1.00 root data:Limit_14", @@ -4549,7 +4549,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) use_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4559,7 +4559,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) */ * from t use index(primary) where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4569,7 +4569,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) force_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4579,7 +4579,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) */ * from t force index(primary) where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4589,7 +4589,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t, primary) ignore_index(t, primary) */ * from t where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t.a, offset:0, count:1", "└─TableReader_15 1.00 root data:TopN_14", @@ -4599,7 +4599,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) use_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "TopN_9 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_18 1.00 root ", @@ -4610,7 +4610,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) */ * from t1 use index(idx_a) where a<10 order by a limit 1;", "Plan": [ "TopN_9 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_18 1.00 root ", @@ -4621,7 +4621,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) force_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "TopN_9 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_18 1.00 root ", @@ -4632,7 +4632,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) */ * from t1 force index(idx_a) where a<10 order by a limit 1;", "Plan": [ "TopN_9 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_18 1.00 root ", @@ -4643,7 +4643,7 @@ "Warn": null }, { - "SQL": "explain select /*+ no_keep_order(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", + "SQL": "explain select /*+ no_order_index(t1, idx_a) ignore_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1;", "Plan": [ "TopN_8 1.00 root test.t1.a, offset:0, count:1", "└─TableReader_16 1.00 root data:TopN_15", @@ -4654,7 +4654,7 @@ "Warn": null }, { - "SQL": "explain select /*+ qb_name(qb, v) keep_order(t1@qb, idx_a) */ * from v", + "SQL": "explain select /*+ qb_name(qb, v) order_index(t1@qb, idx_a) */ * from v", "Plan": [ "Limit_14 1.00 root offset:0, count:1", "└─Projection_19 1.00 root test.t1.a, test.t1.b", @@ -4666,7 +4666,7 @@ "Warn": null }, { - "SQL": "explain select /*+ qb_name(qb, v1) keep_order(t@qb, primary) */ * from v1", + "SQL": "explain select /*+ qb_name(qb, v1) order_index(t@qb, primary) */ * from v1", "Plan": [ "Limit_13 1.00 root offset:0, count:1", "└─TableReader_17 1.00 root data:Limit_16", @@ -4676,7 +4676,7 @@ "Warn": null }, { - "SQL": "explain select /*+ qb_name(qb, v) no_keep_order(t1@qb, idx_a) */ * from v", + "SQL": "explain select /*+ qb_name(qb, v) no_order_index(t1@qb, idx_a) */ * from v", "Plan": [ "TopN_11 1.00 root test.t1.a, offset:0, count:1", "└─IndexLookUp_18 1.00 root ", @@ -4687,7 +4687,7 @@ "Warn": null }, { - "SQL": "explain select /*+ qb_name(qb, v1) no_keep_order(t@qb, primary) */ * from v1", + "SQL": "explain select /*+ qb_name(qb, v1) no_order_index(t@qb, primary) */ * from v1", "Plan": [ "TopN_10 1.00 root test.t.a, offset:0, count:1", "└─TableReader_17 1.00 root data:TopN_16", @@ -4697,7 +4697,7 @@ "Warn": null }, { - "SQL": "explain WITH CTE AS (select /*+ keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "SQL": "explain WITH CTE AS (select /*+ order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ "HashAgg_30 2.00 root group by:Column#8, Column#9, funcs:firstrow(Column#8)->Column#8, funcs:firstrow(Column#9)->Column#9", "└─Union_31 1.28 root ", @@ -4717,7 +4717,7 @@ "Warn": null }, { - "SQL": "explain WITH CTE AS (select /*+ keep_order(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "SQL": "explain WITH CTE AS (select /*+ order_index(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ "HashAgg_28 2.00 root group by:Column#7, Column#8, funcs:firstrow(Column#7)->Column#7, funcs:firstrow(Column#8)->Column#8", "└─Union_29 1.28 root ", @@ -4735,7 +4735,7 @@ "Warn": null }, { - "SQL": "explain WITH CTE AS (select /*+ no_keep_order(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "SQL": "explain WITH CTE AS (select /*+ no_order_index(t1, idx_a) */ * from t1 where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ "HashAgg_29 2.00 root group by:Column#8, Column#9, funcs:firstrow(Column#8)->Column#8, funcs:firstrow(Column#9)->Column#9", "└─Union_30 1.28 root ", @@ -4754,7 +4754,7 @@ "Warn": null }, { - "SQL": "explain WITH CTE AS (select /*+ no_keep_order(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", + "SQL": "explain WITH CTE AS (select /*+ no_order_index(t, primary) */ * from t where a<10 order by a limit 1) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ "HashAgg_28 2.00 root group by:Column#7, Column#8, funcs:firstrow(Column#7)->Column#7, funcs:firstrow(Column#8)->Column#8", "└─Union_29 1.28 root ", @@ -6583,12 +6583,12 @@ { "SQL": "explain format = 'brief' select /*+ qb_name(qb_v7, v7), merge(@qb_v7) */ * from v7;", "Plan": [ - "TableReader 3544.89 root data:ExchangeSender", + "TableReader 3544.89 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3544.89 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 3544.89 mpp[tiflash] Column#14, Column#15", " └─HashAgg 3544.89 mpp[tiflash] group by:Column#14, Column#15, funcs:firstrow(Column#14)->Column#14, funcs:firstrow(Column#15)->Column#15", " └─ExchangeReceiver 3544.89 mpp[tiflash] ", - " └─ExchangeSender 3544.89 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#14, collate: binary], [name: Column#15, collate: binary]", + " └─ExchangeSender 3544.89 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#14, collate: binary], [name: Column#15, collate: binary]", " └─HashAgg 3544.89 mpp[tiflash] group by:Column#14, Column#15, ", " └─Union 4431.11 mpp[tiflash] ", " ├─Projection 3323.33 mpp[tiflash] cast(test.t.a, int(11) BINARY)->Column#14, test.t.b", @@ -6639,7 +6639,7 @@ "SQL": "explain format = 'brief' select /*+ qb_name(qb_v10, v10), LIMIT_TO_COP(@qb_v10) */ * from v10;", "Plan": [ "TopN 1.00 root test.t.b, offset:0, count:1", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─TopN 1.00 mpp[tiflash] test.t.b, offset:0, count:1", " └─Selection 3333.33 mpp[tiflash] gt(test.t.a, 10)", @@ -6650,14 +6650,14 @@ { "SQL": "explain format = 'brief' select /*+ qb_name(qb, v11) read_from_storage(tiflash[t@qb]), MPP_1PHASE_AGG(@qb) */ * from v11;", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#4", " └─Projection 8000.00 mpp[tiflash] Column#4, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#9, funcs:sum(Column#7)->Column#4, funcs:firstrow(Column#8)->test.t.a", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#7, test.t.a, test.t.a", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warn": null @@ -6665,13 +6665,13 @@ { "SQL": "explain format = 'brief' select /*+ qb_name(qb, v11) read_from_storage(tiflash[t@qb]), MPP_2PHASE_AGG(@qb) */ * from v11;", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#4", " └─Projection 8000.00 mpp[tiflash] Column#4, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, funcs:sum(Column#9)->Column#4, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#12, funcs:sum(Column#11)->Column#9", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#11, test.t.a", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -6681,15 +6681,15 @@ { "SQL": "explain format = 'brief' select /*+ qb_name(qb, v12) read_from_storage(tiflash[t1@qb, t@qb]), shuffle_join(t1@qb, t@qb) */ * from v12;", "Plan": [ - "TableReader 12500.00 root data:ExchangeSender", + "TableReader 12500.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12500.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12500.00 mpp[tiflash] test.t.a, test.t.b", " └─HashJoin 12500.00 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ], "Warn": null @@ -6697,7 +6697,7 @@ { "SQL": "explain format = 'brief' select /*+ qb_name(qb, v12) read_from_storage(tiflash[t1@qb, t@qb]), broadcast_join(t1@qb, t@qb) */ * from v12;", "Plan": [ - "TableReader 12500.00 root data:ExchangeSender", + "TableReader 12500.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12500.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12500.00 mpp[tiflash] test.t.a, test.t.b", " └─HashJoin 12500.00 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", @@ -6779,7 +6779,7 @@ { "SQL": "explain format = 'brief' select * from t where t.a = 1", "Result": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableRangeScan 1.00 mpp[tiflash] table:t range:[1,1], keep order:false, stats:pseudo" ] @@ -6787,7 +6787,7 @@ { "SQL": "explain format = 'brief' select * from t where t.a in (1, 2)", "Result": [ - "TableReader 2.00 root data:ExchangeSender", + "TableReader 2.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableRangeScan 2.00 mpp[tiflash] table:t range:[1,1], [2,2], keep order:false, stats:pseudo" ] @@ -6800,7 +6800,7 @@ { "SQL": "explain format = 'brief' select * from t", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -6809,7 +6809,7 @@ { "SQL": "explain format = 'brief' select * from t use index();", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -6818,7 +6818,7 @@ { "SQL": "explain format = 'brief' select /*+ use_index(t, idx)*/ * from t", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -6829,7 +6829,7 @@ { "SQL": "explain format = 'brief' select /*+ use_index(t)*/ * from t", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -7118,7 +7118,7 @@ { "SQL": "desc format = 'brief' select i * 2 from t", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] mul(test.t.i, 2)->Column#13", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7127,7 +7127,7 @@ { "SQL": "desc format = 'brief' select DATE_FORMAT(t, '%Y-%m-%d %H') as date from t", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] date_format(test.t.t, %Y-%m-%d %H)->Column#13", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7154,7 +7154,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#17)->Column#14", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(Column#19)->Column#17", " └─Projection 10000.00 mpp[tiflash] plus(test.t.id, 1)->Column#19", @@ -7165,7 +7165,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(*) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#16)->Column#14", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t._tidb_rowid)->Column#16", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7175,7 +7175,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ sum(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#17)->Column#14", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#19)->Column#17", " └─Projection 10000.00 mpp[tiflash] cast(plus(test.t.id, 1), decimal(20,0) BINARY)->Column#19", @@ -7214,7 +7214,7 @@ { "SQL": "desc format = 'brief' select * from (select id-2 as b from t) B join (select id-2 as b from t) A on A.b=B.b", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 10000.00 mpp[tiflash] inner join, equal:[eq(Column#13, Column#26)]", " ├─ExchangeReceiver(Build) 8000.00 mpp[tiflash] ", @@ -7231,7 +7231,7 @@ "SQL": "desc format = 'brief' select * from t join (select id-2 as b from t) A on A.b=t.id", "Plan": [ "HashJoin 10000.00 root inner join, equal:[eq(test.t.id, Column#25)]", - "├─TableReader(Build) 8000.00 root data:ExchangeSender", + "├─TableReader(Build) 8000.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─Projection 8000.00 mpp[tiflash] minus(test.t.id, 2)->Column#25", "│ └─Selection 8000.00 mpp[tiflash] not(isnull(minus(test.t.id, 2)))", @@ -7245,7 +7245,7 @@ "SQL": "desc format = 'brief' select * from t left join (select id-2 as b from t) A on A.b=t.id", "Plan": [ "HashJoin 10000.00 root left outer join, equal:[eq(test.t.id, Column#25)]", - "├─TableReader(Build) 8000.00 root data:ExchangeSender", + "├─TableReader(Build) 8000.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─Projection 8000.00 mpp[tiflash] minus(test.t.id, 2)->Column#25", "│ └─Selection 8000.00 mpp[tiflash] not(isnull(minus(test.t.id, 2)))", @@ -7258,7 +7258,7 @@ "SQL": "desc format = 'brief' select * from t right join (select id-2 as b from t) A on A.b=t.id", "Plan": [ "HashJoin 12487.50 root right outer join, equal:[eq(test.t.id, Column#25)]", - "├─TableReader(Build) 10000.00 root data:ExchangeSender", + "├─TableReader(Build) 10000.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─Projection 10000.00 mpp[tiflash] minus(test.t.id, 2)->Column#25", "│ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -7270,7 +7270,7 @@ { "SQL": "desc format = 'brief' select A.b, B.b from (select id-2 as b from t) B join (select id-2 as b from t) A on A.b=B.b", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] Column#26, Column#13", " └─HashJoin 10000.00 mpp[tiflash] inner join, equal:[eq(Column#13, Column#26)]", @@ -7287,7 +7287,7 @@ { "SQL": "desc format = 'brief' select A.id from t as A where exists (select 1 from t where t.id=A.id)", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -7301,7 +7301,7 @@ { "SQL": "desc format = 'brief' select A.id from t as A where not exists (select 1 from t where t.id=A.id)", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8000.00 mpp[tiflash] anti semi join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", @@ -7313,7 +7313,7 @@ { "SQL": "desc format = 'brief' SELECT FROM_UNIXTIME(name,'%Y-%m-%d') FROM t;", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] from_unixtime(cast(test.t.name, decimal(65,6) BINARY), %Y-%m-%d)->Column#13", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7487,7 +7487,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#9)->Column#6", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(Column#11)->Column#9", " └─Projection 10000.00 mpp[tiflash] plus(test.t.id, 1)->Column#11", @@ -7498,7 +7498,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(*) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#8)->Column#6", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t._tidb_rowid)->Column#8", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7508,7 +7508,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ sum(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#9)->Column#6", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#11)->Column#9", " └─Projection 10000.00 mpp[tiflash] cast(plus(test.t.id, 1), decimal(20,0) BINARY)->Column#11", @@ -7547,7 +7547,7 @@ { "SQL": "desc format = 'brief' select B.b+A.b from (select id-2 as b from t) B join (select id-2 as b from t) A on A.b=B.b", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] plus(Column#5, Column#10)->Column#11", " └─HashJoin 10000.00 mpp[tiflash] inner join, equal:[eq(Column#5, Column#10)]", @@ -7564,7 +7564,7 @@ { "SQL": "desc format = 'brief' select * from t join (select id-2 as b from t) A on A.b=t.id", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 10000.00 mpp[tiflash] inner join, equal:[eq(test.t.id, Column#9)]", " ├─ExchangeReceiver(Build) 8000.00 mpp[tiflash] ", @@ -7579,7 +7579,7 @@ { "SQL": "desc format = 'brief' select * from t left join (select id-2 as b from t) A on A.b=t.id", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 10000.00 mpp[tiflash] left outer join, equal:[eq(test.t.id, Column#9)]", " ├─ExchangeReceiver(Build) 8000.00 mpp[tiflash] ", @@ -7593,7 +7593,7 @@ { "SQL": "desc format = 'brief' select * from t right join (select id-2 as b from t) A on A.b=t.id", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] right outer join, equal:[eq(test.t.id, Column#9)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -7607,7 +7607,7 @@ { "SQL": "desc format = 'brief' select A.b, B.b from (select id-2 as b from t) B join (select id-2 as b from t) A on A.b=B.b", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] Column#10, Column#5", " └─HashJoin 10000.00 mpp[tiflash] inner join, equal:[eq(Column#5, Column#10)]", @@ -7624,7 +7624,7 @@ { "SQL": "desc format = 'brief' select id from t as A where exists (select 1 from t where t.id=A.id)", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -7638,7 +7638,7 @@ { "SQL": "desc format = 'brief' select id from t as A where not exists (select 1 from t where t.id=A.id)", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8000.00 mpp[tiflash] anti semi join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", @@ -7651,13 +7651,13 @@ "SQL": "desc format = 'brief' select b*2, id from (select avg(value+2) as b, id from t group by id) C order by id", "Plan": [ "Sort 8000.00 root test.t.id", - "└─TableReader 8000.00 root data:ExchangeSender", + "└─TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] mul(Column#5, 2)->Column#6, test.t.id", " └─Projection 8000.00 mpp[tiflash] div(Column#5, cast(case(eq(Column#20, 0), 1, Column#20), decimal(20,0) BINARY))->Column#5, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#21)->Column#20, funcs:sum(Column#22)->Column#5, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#26, funcs:count(Column#24)->Column#21, funcs:sum(Column#25)->Column#22", " └─Projection 10000.00 mpp[tiflash] plus(test.t.value, 2)->Column#24, plus(test.t.value, 2)->Column#25, test.t.id", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7666,7 +7666,7 @@ { "SQL": "desc format = 'brief' SELECT FROM_UNIXTIME(name,'%Y-%m-%d') FROM t;", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] from_unixtime(cast(test.t.name, decimal(65,6) BINARY), %Y-%m-%d)->Column#5", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7680,13 +7680,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(*) c, id from t group by id having id >c", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 6400.00 mpp[tiflash] gt(test.t.id, Column#5)", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#12)->Column#5, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#12", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -7694,7 +7694,7 @@ { "SQL": "desc format = 'brief' select * from t where id < 2", "Plan": [ - "TableReader 3323.33 root data:ExchangeSender", + "TableReader 3323.33 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 3323.33 mpp[tiflash] lt(test.t.id, 2)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7709,7 +7709,7 @@ "SQL": "explain format = 'brief' select count(*) from (select a , b from t union all select a , b from t1) tt", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─Union 20000.00 mpp[tiflash] ", @@ -7723,7 +7723,7 @@ "SQL": "explain format = 'brief' select count(*) from (select a , b from t union all select a , b from t1 union all select a, b from t where false) tt", "Plan": [ "HashAgg 1.00 root funcs:count(Column#16)->Column#15", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#16", " └─Union 20000.00 mpp[tiflash] ", @@ -7737,7 +7737,7 @@ "SQL": "explain format = 'brief' select count(*) from (select a , b from t union all select a , c from t1) tt", "Plan": [ "HashAgg 1.00 root funcs:count(Column#14)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#14", " └─Union 20000.00 mpp[tiflash] ", @@ -7752,7 +7752,7 @@ "SQL": "explain format = 'brief' select count(*) from (select a , b from t union all select a , c from t1 where false) tt", "Plan": [ "HashAgg 1.00 root funcs:count(Column#14)->Column#11", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#14", " └─Union 10000.00 mpp[tiflash] ", @@ -7780,17 +7780,17 @@ { "SQL": "desc format = 'brief' select t1.c1, t1.c2, t2.c1, t2.c2, t2.c3 from t t1 join t t2 on t1.c1 + 1 = t2.c2 - 10 and t1.c1 * 3 = t2.c3 / 2", "Plan": [ - "TableReader 12500.00 root data:ExchangeSender", + "TableReader 12500.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12500.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12500.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c1, test.t.c2, test.t.c3", " └─HashJoin 12500.00 mpp[tiflash] inner join, equal:[eq(Column#13, Column#14) eq(Column#15, Column#16)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#23, collate: binary], [name: Column#24, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#23, collate: binary], [name: Column#24, collate: binary]", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, Column#13, Column#15, cast(Column#13, decimal(13,8) BINARY)->Column#23, cast(Column#15, decimal(10,5) BINARY)->Column#24", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, mul(test.t.c1, 3)->Column#13, plus(test.t.c1, 1)->Column#15", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#14, collate: binary], [name: Column#16, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#14, collate: binary], [name: Column#16, collate: binary]", " └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, div(test.t.c3, 2)->Column#14, minus(test.t.c2, 10)->Column#16", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ] @@ -7798,27 +7798,27 @@ { "SQL": "desc format = 'brief' select * from (select c1, c2, c5, count(*) c from t group by c1, c2, c5) t1 join (select c1, c2, c3, count(*) c from t group by c1, c2, c3) t2 on t1.c1 = t2.c2 and t1.c2 = t2.c3 and t1.c5 = t2.c1", "Plan": [ - "TableReader 7976.02 root data:ExchangeSender", + "TableReader 7976.02 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7976.02 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 7976.02 mpp[tiflash] test.t.c1, test.t.c2, test.t.c5, Column#7, test.t.c1, test.t.c2, test.t.c3, Column#14", " └─HashJoin 7976.02 mpp[tiflash] inner join, equal:[eq(test.t.c1, test.t.c2) eq(test.t.c2, test.t.c3) eq(test.t.c5, test.t.c1)]", " ├─ExchangeReceiver(Build) 7976.02 mpp[tiflash] ", - " │ └─ExchangeSender 7976.02 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#58, collate: binary], [name: test.t.c5, collate: binary]", + " │ └─ExchangeSender 7976.02 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#58, collate: binary], [name: test.t.c5, collate: binary]", " │ └─Projection 7976.02 mpp[tiflash] Column#7, test.t.c1, test.t.c2, test.t.c5, cast(test.t.c2, decimal(10,5))->Column#58", " │ └─Projection 7976.02 mpp[tiflash] Column#7, test.t.c1, test.t.c2, test.t.c5", " │ └─HashAgg 7976.02 mpp[tiflash] group by:test.t.c1, test.t.c2, test.t.c5, funcs:sum(Column#15)->Column#7, funcs:firstrow(test.t.c1)->test.t.c1, funcs:firstrow(test.t.c2)->test.t.c2, funcs:firstrow(test.t.c5)->test.t.c5", " │ └─ExchangeReceiver 7976.02 mpp[tiflash] ", - " │ └─ExchangeSender 7976.02 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c5, collate: binary]", + " │ └─ExchangeSender 7976.02 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c5, collate: binary]", " │ └─HashAgg 7976.02 mpp[tiflash] group by:test.t.c1, test.t.c2, test.t.c5, funcs:count(1)->Column#15", " │ └─Selection 9970.03 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2)), not(isnull(test.t.c5))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 7984.01 mpp[tiflash] ", - " └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#59, collate: binary], [name: Column#60, collate: binary]", + " └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#59, collate: binary], [name: Column#60, collate: binary]", " └─Projection 7984.01 mpp[tiflash] Column#14, test.t.c1, test.t.c2, test.t.c3, cast(test.t.c3, decimal(10,5))->Column#59, cast(test.t.c1, decimal(40,20))->Column#60", " └─Projection 7984.01 mpp[tiflash] Column#14, test.t.c1, test.t.c2, test.t.c3", " └─HashAgg 7984.01 mpp[tiflash] group by:test.t.c1, test.t.c2, test.t.c3, funcs:sum(Column#23)->Column#14, funcs:firstrow(test.t.c1)->test.t.c1, funcs:firstrow(test.t.c2)->test.t.c2, funcs:firstrow(test.t.c3)->test.t.c3", " └─ExchangeReceiver 7984.01 mpp[tiflash] ", - " └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c1, collate: binary]", + " └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c1, collate: binary]", " └─HashAgg 7984.01 mpp[tiflash] group by:test.t.c1, test.t.c2, test.t.c3, funcs:count(1)->Column#23", " └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7827,15 +7827,15 @@ { "SQL": "desc format = 'brief' select * from t t1 join t t2 on t1.c1 = t2.c2 and t1.c2 = t2.c2 and t1.c3 = t2.c3 and t1.c4 = t2.c4 and t1.c5 = t2.c5", "Plan": [ - "TableReader 12462.54 root data:ExchangeSender", + "TableReader 12462.54 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12462.54 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12462.54 mpp[tiflash] inner join, equal:[eq(test.t.c1, test.t.c2) eq(test.t.c2, test.t.c2) eq(test.t.c3, test.t.c3) eq(test.t.c4, test.t.c4) eq(test.t.c5, test.t.c5)]", " ├─ExchangeReceiver(Build) 9970.03 mpp[tiflash] ", - " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c4, collate: binary], [name: test.t.c5, collate: binary]", + " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c4, collate: binary], [name: test.t.c5, collate: binary]", " │ └─Selection 9970.03 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2)), not(isnull(test.t.c5))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9980.01 mpp[tiflash] ", - " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c4, collate: binary], [name: test.t.c5, collate: binary]", + " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary], [name: test.t.c2, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c4, collate: binary], [name: test.t.c5, collate: binary]", " └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.c2)), not(isnull(test.t.c5))", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ] @@ -7843,17 +7843,17 @@ { "SQL": "desc format = 'brief' select * from t t1 join t t2 on t1.c1 = t2.c2 and t1.c2 = t2.c3 and t1.c3 = t2.c1 and t1.c4 = t2.c3 and t1.c1 = t2.c5", "Plan": [ - "TableReader 12462.54 root data:ExchangeSender", + "TableReader 12462.54 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12462.54 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12462.54 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5", " └─HashJoin 12462.54 mpp[tiflash] inner join, equal:[eq(test.t.c2, test.t.c1) eq(test.t.c3, test.t.c2) eq(test.t.c1, test.t.c3) eq(test.t.c3, test.t.c4) eq(test.t.c5, test.t.c1)]", " ├─ExchangeReceiver(Build) 9970.03 mpp[tiflash] ", - " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#18, collate: binary], [name: Column#20, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c5, collate: binary]", + " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#18, collate: binary], [name: Column#20, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c5, collate: binary]", " │ └─Projection 9970.03 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, cast(test.t.c3, decimal(10,5))->Column#18, cast(test.t.c1, decimal(10,5))->Column#20", " │ └─Selection 9970.03 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2)), not(isnull(test.t.c5))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9980.01 mpp[tiflash] ", - " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#19, collate: binary], [name: Column#21, collate: binary], [name: test.t.c4, collate: binary], [name: Column#22, collate: binary]", + " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#19, collate: binary], [name: Column#21, collate: binary], [name: test.t.c4, collate: binary], [name: Column#22, collate: binary]", " └─Projection 9980.01 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, cast(test.t.c2, decimal(10,5))->Column#19, cast(test.t.c3, decimal(10,5))->Column#21, cast(test.t.c1, decimal(40,20))->Column#22", " └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" @@ -7862,17 +7862,17 @@ { "SQL": "desc format = 'brief' select * from t t1 join t t2 on t1.c1 + t1.c2 = t2.c2 / t2.c3", "Plan": [ - "TableReader 12500.00 root data:ExchangeSender", + "TableReader 12500.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12500.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12500.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5", " └─HashJoin 12500.00 mpp[tiflash] inner join, equal:[eq(Column#13, Column#14)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#18, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#18, collate: binary]", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, Column#13, cast(Column#13, decimal(17,9) BINARY)->Column#18", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, plus(test.t.c1, test.t.c2)->Column#13", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#14, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#14, collate: binary]", " └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, div(test.t.c2, test.t.c3)->Column#14", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ] @@ -7880,17 +7880,17 @@ { "SQL": "desc format = 'brief' select * from t t1 where exists (select * from t t2 where t1.c1 = t2.c2 and t1.c2 = t2.c3 and t1.c3 = t2.c1 and t1.c4 = t2.c3 and t1.c1 = t2.c5)", "Plan": [ - "TableReader 7984.01 root data:ExchangeSender", + "TableReader 7984.01 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 7984.01 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5", " └─HashJoin 7984.01 mpp[tiflash] semi join, equal:[eq(test.t.c1, test.t.c2) eq(test.t.c2, test.t.c3) eq(test.t.c3, test.t.c1) eq(test.t.c4, test.t.c3) eq(test.t.c1, test.t.c5)]", " ├─ExchangeReceiver(Build) 9970.03 mpp[tiflash] ", - " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#19, collate: binary], [name: Column#21, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c5, collate: binary]", + " │ └─ExchangeSender 9970.03 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary], [name: Column#19, collate: binary], [name: Column#21, collate: binary], [name: test.t.c3, collate: binary], [name: test.t.c5, collate: binary]", " │ └─Projection 9970.03 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c5, cast(test.t.c3, decimal(10,5))->Column#19, cast(test.t.c1, decimal(10,5))->Column#21", " │ └─Selection 9970.03 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2)), not(isnull(test.t.c5))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9980.01 mpp[tiflash] ", - " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#18, collate: binary], [name: Column#20, collate: binary], [name: test.t.c4, collate: binary], [name: Column#22, collate: binary]", + " └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary], [name: Column#18, collate: binary], [name: Column#20, collate: binary], [name: test.t.c4, collate: binary], [name: Column#22, collate: binary]", " └─Projection 9980.01 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, cast(test.t.c2, decimal(10,5))->Column#18, cast(test.t.c3, decimal(10,5))->Column#20, cast(test.t.c1, decimal(40,20))->Column#22", " └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.c1)), not(isnull(test.t.c2))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" @@ -7899,29 +7899,29 @@ { "SQL": "desc format = 'brief' select * from t t1 left join t t2 on t1.c1 = t2.c2 join t t3 on t2.c5 = t3.c3 right join t t4 on t3.c3 = t4.c4 ", "Plan": [ - "TableReader 19492.21 root data:ExchangeSender", + "TableReader 19492.21 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 19492.21 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 19492.21 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5", " └─HashJoin 19492.21 mpp[tiflash] right outer join, equal:[eq(test.t.c3, test.t.c4)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#29, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#29, collate: binary]", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, cast(test.t.c4, decimal(40,20))->Column#29", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t4 keep order:false, stats:pseudo", " └─Projection(Probe) 15593.77 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t.c5, test.t.c3)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#25, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#25, collate: binary]", " │ └─Projection 10000.00 mpp[tiflash] test.t.c1, test.t.c2, test.t.c3, test.t.c4, test.t.c5, cast(test.t.c3, decimal(40,20))->Column#25", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t3 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 12475.01 mpp[tiflash] ", - " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c5, collate: binary]", + " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c5, collate: binary]", " └─HashJoin 12475.01 mpp[tiflash] inner join, equal:[eq(test.t.c2, test.t.c1)]", " ├─ExchangeReceiver(Build) 9980.01 mpp[tiflash] ", - " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c2, collate: binary]", + " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c2, collate: binary]", " │ └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.c2)), not(isnull(test.t.c5))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c1, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c1, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.c1))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -7929,25 +7929,25 @@ { "SQL": "desc format = 'brief' SELECT STRAIGHT_JOIN t1 . col_varchar_64 , t1 . col_char_64_not_null FROM tt AS t1 INNER JOIN( tt AS t2 JOIN tt AS t3 ON(t3 . col_decimal_30_10_key = t2 . col_tinyint)) ON(t3 . col_varchar_64 = t2 . col_varchar_key) WHERE t3 . col_varchar_64 = t1 . col_char_64_not_null GROUP BY 1 , 2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.tt.col_varchar_64, test.tt.col_char_64_not_null", " └─HashAgg 8000.00 mpp[tiflash] group by:test.tt.col_char_64_not_null, test.tt.col_varchar_64, funcs:firstrow(test.tt.col_varchar_64)->test.tt.col_varchar_64, funcs:firstrow(test.tt.col_char_64_not_null)->test.tt.col_char_64_not_null", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.col_varchar_64, collate: utf8mb4_bin], [name: test.tt.col_char_64_not_null, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.col_varchar_64, collate: utf8mb4_bin], [name: test.tt.col_char_64_not_null, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.tt.col_char_64_not_null, test.tt.col_varchar_64, ", " └─HashJoin 15609.38 mpp[tiflash] inner join, equal:[eq(test.tt.col_char_64_not_null, test.tt.col_varchar_64)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.col_char_64_not_null, collate: utf8mb4_bin]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.col_char_64_not_null, collate: utf8mb4_bin]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─HashJoin(Probe) 12487.50 mpp[tiflash] inner join, equal:[eq(test.tt.col_varchar_key, test.tt.col_varchar_64) eq(Column#19, test.tt.col_decimal_30_10_key)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.col_varchar_key, collate: utf8mb4_bin]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.col_varchar_key, collate: utf8mb4_bin]", " │ └─Projection 9990.00 mpp[tiflash] test.tt.col_varchar_key, cast(test.tt.col_tinyint, decimal(3,0) BINARY)->Column#19", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.tt.col_varchar_key))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.col_varchar_64, collate: utf8mb4_bin]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.col_varchar_64, collate: utf8mb4_bin]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.tt.col_varchar_64))", " └─TableFullScan 10000.00 mpp[tiflash] table:t3 keep order:false, stats:pseudo" ] @@ -7960,16 +7960,16 @@ { "SQL": "desc format = 'brief' select * from tt t1 where exists (select * from t t2 where t1.b1 = t2.c3 and t2.c1 < t2.c2)", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.tt.b1, test.t.c3)]", " ├─ExchangeReceiver(Build) 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c3, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c3, collate: binary]", " │ └─Projection 8000.00 mpp[tiflash] test.t.c3", " │ └─Selection 8000.00 mpp[tiflash] lt(test.t.c1, test.t.c2)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.b1, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.b1, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.tt.b1))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -7982,16 +7982,16 @@ { "SQL": "desc format = 'brief' select * from tt t1 where exists (select * from t t2 where t1.b1 = t2.c3 and t2.c1 < t2.c2)", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.tt.b1, test.t.c3)], stream_count: 8", " ├─ExchangeReceiver(Build) 8000.00 mpp[tiflash] stream_count: 8", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.c3, collate: binary], stream_count: 8", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.c3, collate: binary], stream_count: 8", " │ └─Projection 8000.00 mpp[tiflash] test.t.c3", " │ └─Selection 8000.00 mpp[tiflash] lt(test.t.c1, test.t.c2)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.b1, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.b1, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.tt.b1))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -7999,18 +7999,100 @@ { "SQL": "desc format = 'brief' select count(*) from tt group by b1", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#3", " └─HashAgg 8000.00 mpp[tiflash] group by:test.tt.b1, funcs:sum(Column#7)->Column#3, stream_count: 8", " └─ExchangeReceiver 8000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tt.b1, collate: binary], stream_count: 8", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tt.b1, collate: binary], stream_count: 8", " └─HashAgg 8000.00 mpp[tiflash] group by:test.tt.b1, funcs:count(1)->Column#7", " └─TableFullScan 10000.00 mpp[tiflash] table:tt keep order:false, stats:pseudo" ] } ] }, + { + "Name": "TestMppVersion", + "Cases": [ + { + "SQL": "desc format = 'brief' select count(*) as cnt from t group by a, b", + "Plan": [ + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", + "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", + " └─Projection 8000.00 mpp[tiflash] Column#4", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:sum(Column#8)->Column#4", + " └─ExchangeReceiver 8000.00 mpp[tiflash] ", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary]", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:count(1)->Column#8", + " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" + ] + }, + { + "SQL": "set mpp_exchange_compression_mode = UNSPECIFIED", + "Plan": null, + "Warnings": null + }, + { + "SQL": "desc format = 'brief' select count(*) as cnt from t group by a, b", + "Plan": [ + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", + "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", + " └─Projection 8000.00 mpp[tiflash] Column#4", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:sum(Column#8)->Column#4", + " └─ExchangeReceiver 8000.00 mpp[tiflash] ", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary]", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:count(1)->Column#8", + " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" + ] + }, + { + "SQL": "set mpp_version = 0", + "Plan": null, + "Warnings": null + }, + { + "SQL": "set mpp_exchange_compression_mode = fast", + "Plan": null, + "Warnings": null + }, + { + "SQL": "desc format = 'brief' select count(*) as cnt from t group by a, b", + "Plan": [ + "TableReader 8000.00 root MppVersion: 0, data:ExchangeSender", + "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", + " └─Projection 8000.00 mpp[tiflash] Column#4", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:sum(Column#8)->Column#4", + " └─ExchangeReceiver 8000.00 mpp[tiflash] ", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary]", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:count(1)->Column#8", + " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" + ] + }, + { + "SQL": "set mpp_version = -1", + "Plan": null, + "Warnings": null + }, + { + "SQL": "set mpp_exchange_compression_mode = high_compression", + "Plan": null, + "Warnings": null + }, + { + "SQL": "desc format = 'brief' select count(*) as cnt from t group by a, b", + "Plan": [ + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", + "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", + " └─Projection 8000.00 mpp[tiflash] Column#4", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:sum(Column#8)->Column#4", + " └─ExchangeReceiver 8000.00 mpp[tiflash] ", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: HIGH_COMPRESSION, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.b, collate: binary]", + " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.b, funcs:count(1)->Column#8", + " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" + ] + } + ] + }, { "Name": "TestPushDownAggForMPP", "Cases": [ @@ -8018,7 +8100,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#8)->Column#5", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(Column#10)->Column#8", " └─Projection 10000.00 mpp[tiflash] plus(test.t.id, 1)->Column#10", @@ -8029,7 +8111,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ count(*) from (select id+1 from t)A", "Plan": [ "HashAgg 1.00 root funcs:count(Column#7)->Column#5", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t._tidb_rowid)->Column#7", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -8039,7 +8121,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg()*/ sum(b) from (select id + 1 as b from t)A", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#8)->Column#5", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#10)->Column#8", " └─Projection 10000.00 mpp[tiflash] cast(plus(test.t.id, 1), decimal(20,0) BINARY)->Column#10", @@ -8058,12 +8140,12 @@ { "SQL": "desc format = 'brief' select count(*), id from t group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#11)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#11", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8071,13 +8153,13 @@ { "SQL": "desc format = 'brief' select count(*), id + 1 from t group by id + 1", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#4, plus(test.t.id, 1)->Column#5", " └─Projection 8000.00 mpp[tiflash] Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#16, funcs:sum(Column#17)->Column#4, funcs:firstrow(Column#18)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#16, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#16, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#20, funcs:count(1)->Column#17, funcs:firstrow(Column#19)->Column#18", " └─Projection 10000.00 mpp[tiflash] test.t.id, plus(test.t.id, 1)->Column#20", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -8086,18 +8168,18 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(*), id from t group by id) as A on A.id = t.id", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─Projection(Build) 7992.00 mpp[tiflash] Column#7, test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#8)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#8", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8107,7 +8189,7 @@ "Plan": [ "HashJoin 1.25 root inner join, equal:[eq(test.t.id, Column#7)]", "├─HashAgg(Build) 1.00 root funcs:count(Column#11)->Column#7", - "│ └─TableReader 1.00 root data:ExchangeSender", + "│ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t._tidb_rowid)->Column#11", "│ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8119,12 +8201,12 @@ { "SQL": "desc format = 'brief' select avg(value) as b,id from t group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#17, 0), 1, Column#17), decimal(20,0) BINARY))->Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#18)->Column#17, funcs:sum(Column#19)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(test.t.value)->Column#18, funcs:sum(test.t.value)->Column#19", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8133,13 +8215,13 @@ "SQL": "desc format = 'brief' select /*+hash_agg()*/ sum(b) from (select avg(value) as b, id from t group by id)A", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#18)->Column#5", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#4)->Column#18", " └─Projection 8000.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#15, 0), 1, Column#15), decimal(20,0) BINARY))->Column#4", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#16)->Column#15, funcs:sum(Column#17)->Column#4", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(test.t.value)->Column#16, funcs:sum(test.t.value)->Column#17", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8147,14 +8229,14 @@ { "SQL": "desc format = 'brief' select id from t group by id having avg(value)>0", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 6400.00 mpp[tiflash] test.t.id", " └─Selection 6400.00 mpp[tiflash] gt(Column#4, 0)", " └─Projection 8000.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#18, 0), 1, Column#18), decimal(20,0) BINARY))->Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#19)->Column#18, funcs:sum(Column#20)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(test.t.value)->Column#19, funcs:sum(test.t.value)->Column#20", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8162,13 +8244,13 @@ { "SQL": "desc format = 'brief' select avg(value),id from t group by id having avg(value)>0", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 6400.00 mpp[tiflash] gt(Column#4, 0)", " └─Projection 8000.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#19, 0), 1, Column#19), decimal(20,0) BINARY))->Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#20)->Column#19, funcs:sum(Column#21)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(test.t.value)->Column#20, funcs:sum(test.t.value)->Column#21", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8176,13 +8258,13 @@ { "SQL": "desc format = 'brief' select avg(value) +1,id from t group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] plus(Column#4, 1)->Column#5, test.t.id", " └─Projection 8000.00 mpp[tiflash] div(Column#4, cast(case(eq(Column#19, 0), 1, Column#19), decimal(20,0) BINARY))->Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#20)->Column#19, funcs:sum(Column#21)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(test.t.value)->Column#20, funcs:sum(test.t.value)->Column#21", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8190,18 +8272,18 @@ { "SQL": "desc format = 'brief' select sum(b) from (select t.id, t1.id as b from t join t t1 on t.id=t1.id)A group by id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 7992.00 mpp[tiflash] Column#7", " └─HashAgg 7992.00 mpp[tiflash] group by:Column#12, funcs:sum(Column#11)->Column#7", " └─Projection 12487.50 mpp[tiflash] cast(test.t.id, decimal(10,0) BINARY)->Column#11, test.t.id", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -8209,13 +8291,13 @@ { "SQL": "desc format = 'brief' select * from (select id from t group by id) C join (select sum(b),id from (select t.id, t1.id as b from t join (select id, count(*) as c from t group by id) t1 on t.id=t1.id)A group by id)B on C.id=b.id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─Projection(Build) 7992.00 mpp[tiflash] test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, ", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8226,12 +8308,12 @@ " ├─Projection(Build) 7992.00 mpp[tiflash] test.t.id, Column#13", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id, funcs:sum(Column#17)->Column#13", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#17", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8239,12 +8321,12 @@ { "SQL": "desc format = 'brief' select count(distinct value),id from t group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#4, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(distinct test.t.value)->Column#4, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.value, ", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8260,18 +8342,18 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(distinct value), id from t group by id) as A on A.id = t.id", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─Projection(Build) 7992.00 mpp[tiflash] Column#7, test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:count(distinct test.t.value)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, test.t.value, ", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8279,19 +8361,19 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(1/value), id from t group by id) as A on A.id = t.id", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─Projection(Build) 7992.00 mpp[tiflash] Column#7, test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#8)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:Column#19, funcs:count(Column#18)->Column#8", " │ └─Projection 9990.00 mpp[tiflash] div(1, test.t.value)->Column#18, test.t.id", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8299,7 +8381,7 @@ { "SQL": "desc format = 'brief' select /*+hash_agg()*/ sum(id) from (select value, id from t where id > value group by id, value)A group by value /*the exchange should have only one partition column: test.t.value*/", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 6400.00 mpp[tiflash] Column#4", " └─HashAgg 6400.00 mpp[tiflash] group by:Column#21, funcs:sum(Column#20)->Column#4", @@ -8307,7 +8389,7 @@ " └─Projection 6400.00 mpp[tiflash] test.t.id, test.t.value", " └─HashAgg 6400.00 mpp[tiflash] group by:test.t.id, test.t.value, funcs:firstrow(test.t.id)->test.t.id, funcs:firstrow(test.t.value)->test.t.value", " └─ExchangeReceiver 6400.00 mpp[tiflash] ", - " └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.value, collate: binary]", + " └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.value, collate: binary]", " └─HashAgg 6400.00 mpp[tiflash] group by:test.t.id, test.t.value, ", " └─Selection 8000.00 mpp[tiflash] gt(cast(test.t.id, decimal(10,0) BINARY), test.t.value)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -8316,7 +8398,7 @@ { "SQL": "desc format = 'brief' select /*+hash_agg()*/ sum(B.value) from t as B where B.id+1 > (select count(*) from t where t.id= B.id and t.value=B.value) group by B.id /*the exchange should have only one partition column: test.t.id*/", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 6400.00 mpp[tiflash] Column#8", " └─HashAgg 6400.00 mpp[tiflash] group by:test.t.id, funcs:sum(test.t.value)->Column#8", @@ -8325,19 +8407,19 @@ " ├─Projection(Build) 7984.01 mpp[tiflash] Column#7, test.t.id, test.t.value", " │ └─HashAgg 7984.01 mpp[tiflash] group by:test.t.id, test.t.value, funcs:sum(Column#24)->Column#7, funcs:firstrow(test.t.id)->test.t.id, funcs:firstrow(test.t.value)->test.t.value", " │ └─ExchangeReceiver 7984.01 mpp[tiflash] ", - " │ └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7984.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7984.01 mpp[tiflash] group by:test.t.id, test.t.value, funcs:count(1)->Column#24", " │ └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.id)), not(isnull(test.t.value))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:B keep order:false, stats:pseudo" ] }, { "SQL": "desc format = 'brief' select count(distinct value) from t", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#4", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#6)->Column#4", @@ -8345,7 +8427,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.t.value)->Column#6", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.value, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.value, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.t.value, ", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8353,7 +8435,7 @@ { "SQL": "desc format = 'brief' select count(distinct x ) from (select count(distinct value) x from t) t", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct Column#4)->Column#5", @@ -8363,7 +8445,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.t.value)->Column#7", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.value, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.value, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.t.value, ", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8371,7 +8453,7 @@ { "SQL": "desc format = 'brief' select count(distinct value), count(value), avg(value) from t", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#4, Column#5, div(Column#6, cast(case(eq(Column#15, 0), 1, Column#15), decimal(20,0) BINARY))->Column#6", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#19)->Column#4, funcs:sum(Column#20)->Column#5, funcs:sum(Column#21)->Column#15, funcs:sum(Column#22)->Column#6", @@ -8379,7 +8461,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.t.value)->Column#19, funcs:sum(Column#16)->Column#20, funcs:sum(Column#17)->Column#21, funcs:sum(Column#18)->Column#22", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.value, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.value, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.t.value, funcs:count(test.t.value)->Column#16, funcs:count(test.t.value)->Column#17, funcs:sum(test.t.value)->Column#18", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -8392,7 +8474,7 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(*), id from t group by id) as A on A.id = t.id", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 7992.00 mpp[tiflash] ", @@ -8400,7 +8482,7 @@ " │ └─Projection 7992.00 mpp[tiflash] Column#7, test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#8)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#8", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8411,7 +8493,7 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(*)+id as v from t group by id) as A on A.v = t.id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8000.00 mpp[tiflash] inner join, equal:[eq(test.t.id, Column#8)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", @@ -8421,7 +8503,7 @@ " │ └─Projection 8000.00 mpp[tiflash] Column#7, test.t.id", " │ └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#11)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#11", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t.id))", @@ -8431,7 +8513,7 @@ { "SQL": "desc format = 'brief' select * from t join ( select count(*) as v, id from t group by value,id having value+v <10) as A on A.id = t.id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 7992.00 mpp[tiflash] test.t.id, test.t.value, Column#7, test.t.id", " └─HashJoin 7992.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8441,7 +8523,7 @@ " │ └─Projection 7992.00 mpp[tiflash] Column#7, test.t.id, test.t.value", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, test.t.value, funcs:sum(Column#10)->Column#7, funcs:firstrow(test.t.id)->test.t.id, funcs:firstrow(test.t.value)->test.t.value", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.value, collate: binary], [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.value, collate: binary], [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, test.t.value, funcs:count(1)->Column#10", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8454,7 +8536,7 @@ "Plan": [ "HashJoin 1.25 root inner join, equal:[eq(test.t.id, Column#7)]", "├─HashAgg(Build) 1.00 root funcs:count(Column#10)->Column#7", - "│ └─TableReader 1.00 root data:ExchangeSender", + "│ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t._tidb_rowid)->Column#10", "│ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8466,13 +8548,13 @@ { "SQL": "desc format = 'brief' select sum(b) from (select t.id, t1.id as b from t join t t1 on t.id=t1.id)A group by id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 7992.00 mpp[tiflash] Column#7", " └─HashAgg 7992.00 mpp[tiflash] group by:Column#12, funcs:sum(Column#11)->Column#7", " └─Projection 12487.50 mpp[tiflash] cast(test.t.id, decimal(10,0) BINARY)->Column#11, test.t.id", " └─ExchangeReceiver 12487.50 mpp[tiflash] ", - " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -8485,7 +8567,7 @@ { "SQL": "desc format = 'brief' select * from (select id from t group by id) C join (select sum(value),id from t group by id)B on C.id=B.id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 7992.00 mpp[tiflash] ", @@ -8493,14 +8575,14 @@ " │ └─Projection 7992.00 mpp[tiflash] test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, ", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─Projection(Probe) 7992.00 mpp[tiflash] Column#7, test.t.id", " └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:sum(Column#9)->Column#7, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:sum(test.t.value)->Column#9", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -8509,7 +8591,7 @@ { "SQL": "desc format = 'brief' select * from (select id from t group by id) C join (select sum(b),id from (select t.id, t1.id as b from t join (select id, count(*) as c from t group by id) t1 on t.id=t1.id)A group by id)B on C.id=b.id", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 7992.00 mpp[tiflash] ", @@ -8517,7 +8599,7 @@ " │ └─Projection 7992.00 mpp[tiflash] test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, ", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8525,14 +8607,14 @@ " └─HashAgg 7992.00 mpp[tiflash] group by:Column#34, funcs:sum(Column#32)->Column#11, funcs:firstrow(Column#33)->test.t.id", " └─Projection 9990.00 mpp[tiflash] cast(test.t.id, decimal(10,0) BINARY)->Column#32, test.t.id, test.t.id", " └─ExchangeReceiver 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", " ├─ExchangeReceiver(Build) 7992.00 mpp[tiflash] ", " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: Broadcast", " │ └─Projection 7992.00 mpp[tiflash] test.t.id, Column#13", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id, funcs:sum(Column#16)->Column#13", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:count(1)->Column#16", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -8544,7 +8626,7 @@ "SQL": "desc format = 'brief' select * from t join t t1 on t.id = t1.id order by t.value limit 1", "Plan": [ "TopN 1.00 root test.t.value, offset:0, count:1", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─TopN 1.00 mpp[tiflash] test.t.value, offset:0, count:1", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8562,7 +8644,7 @@ "Projection 1.00 root test.t.id, test.t.value, test.t.id, test.t.value", "└─TopN 1.00 root Column#8, offset:0, count:1", " └─Projection 1.00 root test.t.id, test.t.value, test.t.id, test.t.value, mod(test.t.value, 100)->Column#8", - " └─TableReader 1.00 root data:ExchangeSender", + " └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] test.t.id, test.t.value, test.t.id, test.t.value", " └─TopN 1.00 mpp[tiflash] Column#7, offset:0, count:1", @@ -8581,7 +8663,7 @@ "Plan": [ "StreamAgg 20.00 root group by:test.t.value, funcs:count(1)->Column#7", "└─TopN 20.00 root test.t.value, offset:0, count:20", - " └─TableReader 20.00 root data:ExchangeSender", + " └─TableReader 20.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 20.00 mpp[tiflash] ExchangeType: PassThrough", " └─TopN 20.00 mpp[tiflash] test.t.value, offset:0, count:20", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8597,7 +8679,7 @@ "SQL": "desc format = 'brief' select * from t join t t1 on t.id = t1.id limit 1", "Plan": [ "Limit 1.00 root offset:0, count:1", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Limit 1.00 mpp[tiflash] offset:0, count:1", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8613,7 +8695,7 @@ "SQL": "desc format = 'brief' select * from t join t t1 on t.id = t1.id limit 1", "Plan": [ "Limit 1.00 root offset:0, count:1", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Limit 1.00 mpp[tiflash] offset:0, count:1", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8630,7 +8712,7 @@ "Plan": [ "HashAgg 20.00 root group by:test.t.value, funcs:count(1)->Column#7", "└─Limit 20.00 root offset:0, count:20", - " └─TableReader 20.00 root data:ExchangeSender", + " └─TableReader 20.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 20.00 mpp[tiflash] ExchangeType: PassThrough", " └─Limit 20.00 mpp[tiflash] offset:0, count:20", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -8757,12 +8839,12 @@ "└─HashJoin 9990.00 root CARTESIAN inner join, other cond:or(ge(test.ts.col_char_64_not_null, Column#25), if(ne(Column#26, 0), NULL, 0))", " ├─Selection(Build) 0.80 root ne(Column#27, 0)", " │ └─HashAgg 1.00 root funcs:min(Column#36)->Column#25, funcs:sum(Column#37)->Column#26, funcs:count(Column#38)->Column#27", - " │ └─TableReader 1.00 root data:ExchangeSender", + " │ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:min(Column#42)->Column#36, funcs:sum(Column#43)->Column#37, funcs:count(1)->Column#38", " │ └─Projection 10000.00 mpp[tiflash] test.ts.col_varchar_64, cast(isnull(test.ts.col_varchar_64), decimal(20,0) BINARY)->Column#43", " │ └─TableFullScan 10000.00 mpp[tiflash] table:SUBQUERY4_t1 keep order:false, stats:pseudo", - " └─TableReader(Probe) 12487.50 root data:ExchangeSender", + " └─TableReader(Probe) 12487.50 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.ts.col_varchar_64, test.ts.col_varchar_key)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -8782,7 +8864,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id) from ts", "Plan": [ "HashAgg 1.00 root funcs:group_concat(Column#7 separator \",\")->Column#5", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#9, Column#10, Column#11 separator \",\")->Column#7", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#11", @@ -8795,7 +8877,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#6, Column#7, Column#8 separator \",\")->Column#5", @@ -8812,7 +8894,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id order by col_0) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#6, Column#7, Column#8 order by Column#9 separator \",\")->Column#5", @@ -8828,7 +8910,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id order by col_0) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#6, Column#7, Column#8 order by Column#9 separator \",\")->Column#5", @@ -8845,7 +8927,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id order by col_0),count(*),min(col_1) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#8, Column#9, Column#10 order by Column#11 separator \",\")->Column#5, funcs:count(1)->Column#6, funcs:min(Column#12)->Column#7", @@ -8861,7 +8943,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id order by col_0),count(*),max(col_0) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#12, Column#13, Column#14 order by Column#15 separator \",\")->Column#5, funcs:sum(Column#16)->Column#6, funcs:max(Column#17)->Column#7", @@ -8878,13 +8960,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:group_concat(Column#10, Column#11, Column#12 separator \",\")->Column#5", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#12, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -8894,13 +8976,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#9, funcs:group_concat(distinct Column#6, Column#7, Column#8 separator \",\")->Column#5", " └─Projection 8000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#8, test.ts.col_2", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.ts.col_0, test.ts.col_1, test.ts.col_2, test.ts.id, ", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -8911,13 +8993,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id order by col_0) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, funcs:group_concat(Column#6, Column#7, Column#8 order by Column#9 separator \",\")->Column#5", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#8, test.ts.col_0, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -8927,13 +9009,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id order by col_0) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, funcs:group_concat(distinct Column#6, Column#7, Column#8 order by Column#9 separator \",\")->Column#5", " └─Projection 8000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#8, test.ts.col_0, test.ts.col_2", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.ts.col_0, test.ts.col_1, test.ts.col_2, test.ts.id, ", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -8944,13 +9026,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_1, id order by col_0) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#9, funcs:group_concat(Column#6, Column#7 order by Column#8 separator \",\")->Column#5", " └─Projection 10000.00 mpp[tiflash] test.ts.col_1, cast(test.ts.id, var_string(20))->Column#7, test.ts.col_0, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -8960,13 +9042,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_1, id order by col_0) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#9, funcs:group_concat(distinct Column#6, Column#7 order by Column#8 separator \",\")->Column#5", " └─Projection 8000.00 mpp[tiflash] test.ts.col_1, cast(test.ts.id, var_string(20))->Column#7, test.ts.col_0, test.ts.col_2", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.ts.col_1, test.ts.col_2, test.ts.id, funcs:firstrow(test.ts.col_0)->test.ts.col_0", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -8977,13 +9059,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id order by col_0),count(*),min(col_0),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#11, 0), 1, Column#11), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#20, funcs:group_concat(Column#13, Column#14, Column#15 order by Column#16 separator \",\")->Column#5, funcs:count(1)->Column#6, funcs:min(Column#17)->Column#7, funcs:count(Column#18)->Column#11, funcs:sum(Column#19)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#15, test.ts.col_0, test.ts.col_0, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#19, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -8993,13 +9075,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id order by col_0),count(*),max(col_1),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#19, 0), 1, Column#19), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#32, funcs:group_concat(distinct Column#25, Column#26, Column#27 order by Column#28 separator \",\")->Column#5, funcs:count(1)->Column#6, funcs:max(Column#29)->Column#7, funcs:count(Column#30)->Column#19, funcs:sum(Column#31)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#27, test.ts.col_0, test.ts.col_1, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#31, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9009,7 +9091,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id order by col_0),count(distinct id),min(col_0),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#10, 0), 1, Column#10), decimal(20,0) BINARY))->Column#8", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#11, Column#12, Column#13 order by Column#14 separator \",\")->Column#5, funcs:count(Column#15)->Column#6, funcs:min(Column#16)->Column#7, funcs:count(Column#17)->Column#10, funcs:sum(Column#18)->Column#8", @@ -9025,7 +9107,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id order by col_0),count(distinct id),max(col_1),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#14, 0), 1, Column#14), decimal(20,0) BINARY))->Column#8", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#26, Column#27, Column#28 order by Column#29 separator \",\")->Column#5, funcs:sum(Column#30)->Column#6, funcs:max(Column#31)->Column#7, funcs:sum(Column#32)->Column#14, funcs:sum(Column#33)->Column#8", @@ -9043,13 +9125,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id),count(distinct id),min(col_0),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#26, 0), 1, Column#26), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#40, funcs:group_concat(Column#33, Column#34, Column#35 separator \",\")->Column#5, funcs:count(Column#36)->Column#6, funcs:min(Column#37)->Column#7, funcs:count(Column#38)->Column#26, funcs:sum(Column#39)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#35, test.ts.id, test.ts.col_0, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#39, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9059,13 +9141,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id),count(distinct id),max(col_1),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#19, 0), 1, Column#19), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#32, funcs:group_concat(distinct Column#25, Column#26, Column#27 separator \",\")->Column#5, funcs:count(Column#28)->Column#6, funcs:max(Column#29)->Column#7, funcs:count(Column#30)->Column#19, funcs:sum(Column#31)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#27, test.ts.id, test.ts.col_1, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#31, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9076,7 +9158,7 @@ "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id),count(distinct id),min(col_0),avg(id) from ts", "Plan": [ "HashAgg 1.00 root funcs:group_concat(Column#14 separator \",\")->Column#5, funcs:count(Column#15)->Column#6, funcs:min(Column#16)->Column#7, funcs:avg(Column#17, Column#18)->Column#8", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#24, Column#25, Column#26 separator \",\")->Column#14, funcs:count(Column#27)->Column#15, funcs:min(Column#28)->Column#16, funcs:count(Column#29)->Column#17, funcs:sum(Column#30)->Column#18", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#26, test.ts.id, test.ts.col_0, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#30", @@ -9089,7 +9171,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id),count(distinct id),max(col_1),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#14, 0), 1, Column#14), decimal(20,0) BINARY))->Column#8", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#26, Column#27, Column#28 separator \",\")->Column#5, funcs:sum(Column#29)->Column#6, funcs:max(Column#30)->Column#7, funcs:sum(Column#31)->Column#14, funcs:sum(Column#32)->Column#8", @@ -9107,13 +9189,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_1, id),count(distinct id),group_concat(col_0 order by 1),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#17, 0), 1, Column#17), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#29, funcs:group_concat(Column#21, Column#22, Column#23 separator \",\")->Column#5, funcs:count(Column#24)->Column#6, funcs:group_concat(Column#25 order by Column#26 separator \",\")->Column#7, funcs:count(Column#27)->Column#17, funcs:sum(Column#28)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#23, test.ts.id, test.ts.col_0, test.ts.col_0, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#28, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9123,13 +9205,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0),count(distinct id),group_concat(col_1, id order by 1,2),avg(id) from ts group by col_2", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, div(Column#8, cast(case(eq(Column#13, 0), 1, Column#13), decimal(20,0) BINARY))->Column#8", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#24, funcs:group_concat(distinct Column#16 separator \",\")->Column#5, funcs:count(Column#17)->Column#6, funcs:group_concat(Column#18, Column#19 order by Column#20, Column#21 separator \",\")->Column#7, funcs:count(Column#22)->Column#13, funcs:sum(Column#23)->Column#8", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.id, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#19, test.ts.col_1, test.ts.id, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#23, test.ts.col_2", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_2, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9139,7 +9221,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, id),count(distinct id),group_concat(col_1, id order by 1,2),min(col_0),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, Column#8, div(Column#9, cast(case(eq(Column#15, 0), 1, Column#15), decimal(20,0) BINARY))->Column#9", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(Column#18, Column#19 separator \",\")->Column#5, funcs:count(Column#20)->Column#6, funcs:group_concat(Column#21, Column#22 order by Column#23, Column#24 separator \",\")->Column#7, funcs:min(Column#25)->Column#8, funcs:count(Column#26)->Column#15, funcs:sum(Column#27)->Column#9", @@ -9155,7 +9237,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id),count(distinct id),group_concat(col_1, id order by 1,2),max(col_1),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, Column#8, div(Column#9, cast(case(eq(Column#12, 0), 1, Column#12), decimal(20,0) BINARY))->Column#9", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#14, Column#15, Column#16 separator \",\")->Column#5, funcs:count(Column#17)->Column#6, funcs:group_concat(Column#18, Column#19 order by Column#20, Column#21 separator \",\")->Column#7, funcs:max(Column#22)->Column#8, funcs:count(Column#23)->Column#12, funcs:sum(Column#24)->Column#9", @@ -9171,7 +9253,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id),count(distinct col_2),group_concat(col_1, id),max(col_1),avg(id) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6, Column#7, Column#8, div(Column#9, cast(case(eq(Column#15, 0), 1, Column#15), decimal(20,0) BINARY))->Column#9", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#29, Column#30, Column#31 separator \",\")->Column#5, funcs:count(distinct Column#32)->Column#6, funcs:group_concat(Column#33 separator \",\")->Column#7, funcs:max(Column#34)->Column#8, funcs:sum(Column#35)->Column#15, funcs:sum(Column#36)->Column#9", @@ -9189,13 +9271,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0, col_1, id),count(distinct col_2),group_concat(col_1, id),max(col_1),avg(id) from ts group by col_0", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, Column#6, Column#7, Column#8, div(Column#9, cast(case(eq(Column#20, 0), 1, Column#20), decimal(20,0) BINARY))->Column#9", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#35, funcs:group_concat(distinct Column#26, Column#27, Column#28 separator \",\")->Column#5, funcs:count(distinct Column#29)->Column#6, funcs:group_concat(Column#30, Column#31 separator \",\")->Column#7, funcs:max(Column#32)->Column#8, funcs:count(Column#33)->Column#20, funcs:sum(Column#34)->Column#9", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#28, test.ts.col_2, test.ts.col_1, cast(test.ts.id, var_string(20))->Column#31, test.ts.col_1, test.ts.id, cast(test.ts.id, decimal(10,0) BINARY)->Column#34, test.ts.col_0", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_0, collate: utf8mb4_bin]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_0, collate: utf8mb4_bin]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9205,7 +9287,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,'GG') from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#10, Column#11 separator \",\")->Column#5", @@ -9224,7 +9306,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,'01') from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#10, Column#11 separator \",\")->Column#5", @@ -9241,7 +9323,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,1) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#10, Column#11 separator \",\")->Column#5", @@ -9258,7 +9340,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,0) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#8, Column#9 separator \",\")->Column#5", @@ -9275,13 +9357,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,10) from ts group by '010'", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] group by:Column#17, funcs:group_concat(distinct Column#15, Column#16 separator \",\")->Column#5", " └─Projection 1.00 mpp[tiflash] cast(Column#13, var_string(20))->Column#15, cast(Column#14, var_string(20))->Column#16, Column#12", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#12, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#12, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:0, 1, 10, ", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -9292,13 +9374,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,0) from ts group by '011'", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] group by:Column#14, funcs:group_concat(distinct Column#12, Column#13 separator \",\")->Column#5", " └─Projection 1.00 mpp[tiflash] cast(Column#11, var_string(20))->Column#12, cast(Column#11, var_string(20))->Column#13, Column#10", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#10, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#10, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:0, 1, ", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -9309,13 +9391,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 0,'GG') from ts group by 'GG'", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] group by:Column#17, funcs:group_concat(distinct Column#15, Column#16 separator \",\")->Column#5", " └─Projection 1.00 mpp[tiflash] cast(Column#13, var_string(20))->Column#15, Column#14, Column#12", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#12, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#12, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:\"GG\", 0, 1, ", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], @@ -9332,7 +9414,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 'GG','GG') from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#7, Column#7 separator \",\")->Column#5", @@ -9348,7 +9430,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 'Gg','GG') from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#8, Column#9 separator \",\")->Column#5", @@ -9364,7 +9446,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct 'GG-10','GG') from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#8, Column#9 separator \",\")->Column#5", @@ -9380,7 +9462,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct '1200-01-01 00:00:00.023',1200) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct Column#10, Column#11 separator \",\")->Column#5", @@ -9399,12 +9481,12 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_0) from ts group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:test.ts.id, funcs:group_concat(test.ts.col_0, test.ts.col_0 separator \",\")->Column#5", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.id, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.id, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9414,13 +9496,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(col_0, col_0,id) from ts group by id", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:group_concat(Column#10, Column#11, Column#12 separator \",\")->Column#5", " └─Projection 10000.00 mpp[tiflash] test.ts.col_0, test.ts.col_0, cast(test.ts.id, var_string(20))->Column#12, test.ts.id", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.id, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.id, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" ], "Warning": [ @@ -9430,7 +9512,7 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0 order by id<10) from ts", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:group_concat(distinct test.ts.col_0 order by Column#7 separator \",\")->Column#5", @@ -9447,12 +9529,12 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0 order by id<10) from ts group by col_1", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:test.ts.col_1, funcs:group_concat(distinct test.ts.col_0 order by Column#8 separator \",\")->Column#5", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_1, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_1, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#11, funcs:firstrow(Column#9)->Column#8", " └─Projection 10000.00 mpp[tiflash] lt(test.ts.id, 10)->Column#9, test.ts.col_1, test.ts.col_0", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" @@ -9464,13 +9546,13 @@ { "SQL": "desc format = 'brief' select /*+ hash_agg(),agg_to_cop() */ group_concat(distinct col_0>10 order by id<10) from ts group by col_1", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#17, funcs:group_concat(distinct Column#15 order by Column#16 separator \",\")->Column#5", " └─Projection 8000.00 mpp[tiflash] cast(Column#10, var_string(20))->Column#15, Column#11, test.ts.col_1", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.ts.col_1, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.ts.col_1, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, Column#14, funcs:firstrow(Column#12)->Column#11", " └─Projection 10000.00 mpp[tiflash] lt(test.ts.id, 10)->Column#12, test.ts.col_1, gt(cast(test.ts.col_0, double BINARY), 10)->Column#14", " └─TableFullScan 10000.00 mpp[tiflash] table:ts keep order:false, stats:pseudo" @@ -9505,12 +9587,12 @@ "Plan": [ "Projection 8000.00 root Column#5", "└─Sort 8000.00 root test.t.id", - " └─TableReader 8000.00 root data:ExchangeSender", + " └─TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.id", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, funcs:sum(Column#7)->Column#5, funcs:firstrow(test.t.id)->test.t.id", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.name, collate: utf8mb4_bin], [name: test.t.id, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.name, collate: utf8mb4_bin], [name: test.t.id, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, funcs:count(1)->Column#7", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -9519,12 +9601,12 @@ "SQL": "desc format = 'brief' select count(*) from (select * from t order by id)a group by name order by 1", "Plan": [ "Sort 8000.00 root Column#5", - "└─TableReader 8000.00 root data:ExchangeSender", + "└─TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.name, funcs:sum(Column#8)->Column#5", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.name, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.name, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.name, funcs:count(1)->Column#8", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -9533,14 +9615,14 @@ "SQL": "desc format = 'brief' select count(*) from (select id,name from t group by id,name order by id,name)a group by name order by 1", "Plan": [ "Sort 8000.00 root Column#5", - "└─TableReader 8000.00 root data:ExchangeSender", + "└─TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.name, funcs:count(1)->Column#5", " └─Projection 8000.00 mpp[tiflash] test.t.id, test.t.name", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, funcs:firstrow(test.t.id)->test.t.id, funcs:firstrow(test.t.name)->test.t.name", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.name, collate: utf8mb4_bin]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.name, collate: utf8mb4_bin]", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, ", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -9549,7 +9631,7 @@ "SQL": "desc format = 'brief' select * from (select id from t group by id order by id)a join t on a.id=t.id order by 1", "Plan": [ "Sort 9990.00 root test.t.id", - "└─TableReader 9990.00 root data:ExchangeSender", + "└─TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 9990.00 mpp[tiflash] test.t.id, test.t.id, test.t.value, test.t.name", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -9558,7 +9640,7 @@ " │ └─Projection 7992.00 mpp[tiflash] test.t.id", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.id, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.id, ", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.id))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -9570,7 +9652,7 @@ "SQL": "desc format = 'brief' select * from (select * from t order by id)a join t on a.id=t.id order by 1", "Plan": [ "Sort 12487.50 root test.t.id", - "└─TableReader 12487.50 root data:ExchangeSender", + "└─TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12487.50 mpp[tiflash] test.t.id, test.t.value, test.t.name, test.t.id, test.t.value, test.t.name", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.id, test.t.id)]", @@ -9585,7 +9667,7 @@ { "SQL": "desc format = 'brief' select * from ((select id from t order by 1) union all (select id+1 from t order by 1))c", "Plan": [ - "TableReader 20000.00 root data:ExchangeSender", + "TableReader 20000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 20000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Union 20000.00 mpp[tiflash] ", " ├─Projection 10000.00 mpp[tiflash] cast(test.t.id, bigint(20) BINARY)->Column#10", @@ -9597,7 +9679,7 @@ { "SQL": "desc format = 'brief' select * from ((select count(*) from (select id,name from t order by id)a group by name,id order by id) union all (select id+1 from t order by 1))c", "Plan": [ - "TableReader 18000.00 root data:ExchangeSender", + "TableReader 18000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 18000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Union 18000.00 mpp[tiflash] ", " ├─Projection 8000.00 mpp[tiflash] cast(Column#12, bigint(21) BINARY)->Column#12", @@ -9605,7 +9687,7 @@ " │ └─Projection 8000.00 mpp[tiflash] Column#5, test.t.id", " │ └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, funcs:sum(Column#19)->Column#5, funcs:firstrow(test.t.id)->test.t.id", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.name, collate: utf8mb4_bin], [name: test.t.id, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.name, collate: utf8mb4_bin], [name: test.t.id, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:test.t.id, test.t.name, funcs:count(1)->Column#19", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─Projection 10000.00 mpp[tiflash] cast(Column#11, bigint(21) BINARY)->Column#12", @@ -9617,7 +9699,7 @@ "SQL": "desc format = 'brief' select * from (select * from t order by id)a order by name", "Plan": [ "Sort 10000.00 root test.t.name", - "└─TableReader 10000.00 root data:ExchangeSender", + "└─TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ] @@ -9631,7 +9713,7 @@ "SQL": "explain format = 'brief' select sum(ps_supplycost) from partsupp, supplier where ps_suppkey = s_suppkey;", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#15)->Column#14", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(test.partsupp.ps_supplycost)->Column#15", " └─Projection 12500.00 mpp[tiflash] test.partsupp.ps_supplycost", @@ -9650,7 +9732,7 @@ { "SQL": "explain format = 'brief' select * from rp_t where a = 1 or a = 20", "Plan": [ - "TableReader 20.00 root partition:p0,p3 data:ExchangeSender", + "TableReader 20.00 root partition:p0,p3 MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 20.00 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 20.00 mpp[tiflash] or(eq(test.rp_t.a, 1), eq(test.rp_t.a, 20))", " └─TableFullScan 10000.00 mpp[tiflash] table:rp_t keep order:false, stats:pseudo, PartitionTableScan:true" @@ -9659,7 +9741,7 @@ { "SQL": "explain format = 'brief' select * from hp_t where a = 1 or a = 20", "Plan": [ - "TableReader 20.00 root partition:p0,p1 data:ExchangeSender", + "TableReader 20.00 root partition:p0,p1 MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 20.00 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 20.00 mpp[tiflash] or(eq(test.hp_t.a, 1), eq(test.hp_t.a, 20))", " └─TableFullScan 10000.00 mpp[tiflash] table:hp_t keep order:false, stats:pseudo, PartitionTableScan:true" @@ -9669,7 +9751,7 @@ "SQL": "explain format = 'brief' select count(*) from rp_t where a = 1 or a = 20", "Plan": [ "HashAgg 1.00 root funcs:count(Column#5)->Column#3", - "└─TableReader 1.00 root partition:p0,p3 data:ExchangeSender", + "└─TableReader 1.00 root partition:p0,p3 MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#5", " └─Selection 20.00 mpp[tiflash] or(eq(test.rp_t.a, 1), eq(test.rp_t.a, 20))", @@ -9680,7 +9762,7 @@ "SQL": "explain format = 'brief' select count(*) from hp_t where a = 1 or a = 20", "Plan": [ "HashAgg 1.00 root funcs:count(Column#5)->Column#3", - "└─TableReader 1.00 root partition:p0,p1 data:ExchangeSender", + "└─TableReader 1.00 root partition:p0,p1 MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#5", " └─Selection 20.00 mpp[tiflash] or(eq(test.hp_t.a, 1), eq(test.hp_t.a, 20))", @@ -9695,30 +9777,30 @@ { "SQL": "explain format = 'brief' select row_number() over w1 from t1 window w1 as (partition by c1 order by c1);", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] Column#5, stream_count: 8", " └─Window 10000.00 mpp[tiflash] row_number()->Column#5 over(partition by test.t1.c1 order by test.t1.c1 rows between current row and current row), stream_count: 8", " └─Sort 10000.00 mpp[tiflash] test.t1.c1, test.t1.c1, stream_count: 8", " └─ExchangeReceiver 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] }, { "SQL": "explain format = 'brief' select row_number() over w1, rank() over w2 from t1 window w1 as (partition by c1 order by c1), w2 as (partition by c2);", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] Column#7, Column#6, stream_count: 8", " └─Window 10000.00 mpp[tiflash] row_number()->Column#7 over(partition by test.t1.c1 order by test.t1.c1 rows between current row and current row), stream_count: 8", " └─Sort 10000.00 mpp[tiflash] test.t1.c1, test.t1.c1, stream_count: 8", " └─ExchangeReceiver 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─Window 10000.00 mpp[tiflash] rank()->Column#6 over(partition by test.t1.c2), stream_count: 8", " └─Sort 10000.00 mpp[tiflash] test.t1.c2, stream_count: 8", " └─ExchangeReceiver 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] }, @@ -9727,34 +9809,34 @@ "Plan": [ "Projection 10.00 root Column#7, Column#6", "└─TopN 10.00 root Column#7, Column#6, offset:0, count:10", - " └─TableReader 10.00 root data:ExchangeSender", + " └─TableReader 10.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 10.00 mpp[tiflash] ExchangeType: PassThrough", " └─TopN 10.00 mpp[tiflash] Column#7, Column#6, offset:0, count:10", " └─Window 10000.00 mpp[tiflash] row_number()->Column#7 over(partition by test.t1.c1 order by test.t1.c1 rows between current row and current row), stream_count: 8", " └─Sort 10000.00 mpp[tiflash] test.t1.c1, test.t1.c1, stream_count: 8", " └─ExchangeReceiver 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─Window 10000.00 mpp[tiflash] rank()->Column#6 over(partition by test.t1.c2), stream_count: 8", " └─Sort 10000.00 mpp[tiflash] test.t1.c2, stream_count: 8", " └─ExchangeReceiver 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] }, { "SQL": "explain format = 'brief' select row_number() over w1, count(c2) from t1 group by c1 having c1 > 10 window w1 as (partition by c2 order by c2);", "Plan": [ - "TableReader 2666.67 root data:ExchangeSender", + "TableReader 2666.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2666.67 mpp[tiflash] Column#6, Column#4, stream_count: 8", " └─Window 2666.67 mpp[tiflash] row_number()->Column#6 over(partition by test.t1.c2 order by test.t1.c2 rows between current row and current row), stream_count: 8", " └─Sort 2666.67 mpp[tiflash] test.t1.c2, test.t1.c2, stream_count: 8", " └─ExchangeReceiver 2666.67 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", + " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c2, collate: binary], stream_count: 8", " └─Projection 2666.67 mpp[tiflash] Column#4, test.t1.c2", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c1, funcs:sum(Column#9)->Column#4, funcs:firstrow(Column#10)->test.t1.c2", " └─ExchangeReceiver 2666.67 mpp[tiflash] ", - " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary]", + " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary]", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c1, funcs:count(test.t1.c2)->Column#9, funcs:firstrow(test.t1.c2)->Column#10", " └─Selection 3333.33 mpp[tiflash] gt(test.t1.c1, 10)", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" @@ -9763,17 +9845,17 @@ { "SQL": "explain format = 'brief' select row_number() over w1, count(c1) from t1 group by c2 having c2 > 10 window w1 as (partition by c1 order by c2);", "Plan": [ - "TableReader 2666.67 root data:ExchangeSender", + "TableReader 2666.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2666.67 mpp[tiflash] Column#6, Column#4, stream_count: 8", " └─Window 2666.67 mpp[tiflash] row_number()->Column#6 over(partition by test.t1.c1 order by test.t1.c2 rows between current row and current row), stream_count: 8", " └─Sort 2666.67 mpp[tiflash] test.t1.c1, test.t1.c2, stream_count: 8", " └─ExchangeReceiver 2666.67 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─Projection 2666.67 mpp[tiflash] Column#4, test.t1.c1, test.t1.c2", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c2, funcs:sum(Column#9)->Column#4, funcs:firstrow(Column#10)->test.t1.c1, funcs:firstrow(test.t1.c2)->test.t1.c2", " └─ExchangeReceiver 2666.67 mpp[tiflash] ", - " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c2, collate: binary]", + " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c2, collate: binary]", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c2, funcs:count(test.t1.c1)->Column#9, funcs:firstrow(test.t1.c1)->Column#10", " └─Selection 3333.33 mpp[tiflash] gt(test.t1.c2, 10)", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" @@ -9782,13 +9864,13 @@ { "SQL": "explain format = 'brief' select row_number() over w1 from t1 a join t1 b on a.c1 = b.c2 window w1 as (partition by a.c1);", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12487.50 mpp[tiflash] Column#8, stream_count: 8", " └─Window 12487.50 mpp[tiflash] row_number()->Column#8 over(partition by test.t1.c1 rows between current row and current row), stream_count: 8", " └─Sort 12487.50 mpp[tiflash] test.t1.c1, stream_count: 8", " └─ExchangeReceiver 12487.50 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t1.c1, test.t1.c2)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -9801,13 +9883,13 @@ { "SQL": "explain format = 'brief' select row_number() over w1 from t1 where c1 < 100 window w1 as (partition by c1 order by c1);", "Plan": [ - "TableReader 3323.33 root data:ExchangeSender", + "TableReader 3323.33 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 3323.33 mpp[tiflash] Column#5, stream_count: 8", " └─Window 3323.33 mpp[tiflash] row_number()->Column#5 over(partition by test.t1.c1 order by test.t1.c1 rows between current row and current row), stream_count: 8", " └─Sort 3323.33 mpp[tiflash] test.t1.c1, test.t1.c1, stream_count: 8", " └─ExchangeReceiver 3323.33 mpp[tiflash] stream_count: 8", - " └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", + " └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary], stream_count: 8", " └─Selection 3323.33 mpp[tiflash] lt(test.t1.c1, 100)", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -9815,7 +9897,7 @@ { "SQL": "explain format = 'brief' select * from t1;", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ] @@ -9823,7 +9905,7 @@ { "SQL": "explain format = 'brief' select row_number() over w1 from t1 window w1 as (order by c1);", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 10000.00 mpp[tiflash] Column#5", " └─Window 10000.00 mpp[tiflash] row_number()->Column#5 over(order by test.t1.c1 rows between current row and current row)", @@ -9836,7 +9918,7 @@ { "SQL": "explain format = 'brief' select row_number() over w1, count(c2) from t1 group by c1 having c1 > 10 window w1 as (partition by c1 order by c2);", "Plan": [ - "TableReader 2666.67 root data:ExchangeSender", + "TableReader 2666.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2666.67 mpp[tiflash] Column#6, Column#4", " └─Window 2666.67 mpp[tiflash] row_number()->Column#6 over(partition by test.t1.c1 order by test.t1.c2 rows between current row and current row)", @@ -9844,7 +9926,7 @@ " └─Projection 2666.67 mpp[tiflash] Column#4, test.t1.c1, test.t1.c2", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c1, funcs:sum(Column#9)->Column#4, funcs:firstrow(test.t1.c1)->test.t1.c1, funcs:firstrow(Column#11)->test.t1.c2", " └─ExchangeReceiver 2666.67 mpp[tiflash] ", - " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.c1, collate: binary]", + " └─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.c1, collate: binary]", " └─HashAgg 2666.67 mpp[tiflash] group by:test.t1.c1, funcs:count(test.t1.c2)->Column#9, funcs:firstrow(test.t1.c2)->Column#11", " └─Selection 3333.33 mpp[tiflash] gt(test.t1.c1, 10)", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" @@ -10226,4 +10308,4 @@ } ] } -] +] \ No newline at end of file diff --git a/planner/core/testdata/join_reorder_suite_out.json b/planner/core/testdata/join_reorder_suite_out.json index e2a6c562726d4..58336dc72da14 100644 --- a/planner/core/testdata/join_reorder_suite_out.json +++ b/planner/core/testdata/join_reorder_suite_out.json @@ -5399,7 +5399,7 @@ { "SQL": "select /*+ straight_join() */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -5419,7 +5419,7 @@ { "SQL": "select /*+ leading(t2) */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", @@ -5440,7 +5440,7 @@ { "SQL": "select /*+ leading(t3) */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t2.a, test.t1.a)]", @@ -5461,7 +5461,7 @@ { "SQL": "select /*+ leading(t2, t3) */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t2.a, test.t1.a)]", @@ -5482,7 +5482,7 @@ { "SQL": "select /*+ leading(t3, t2) */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t2.a, test.t1.a)]", @@ -5503,7 +5503,7 @@ { "SQL": "select /*+ leading(t3, t1) */ * from t1 join t2 on t1.a=t2.a join t3 on t2.b=t3.b", "Plan": [ - "TableReader 124625374.88 root data:ExchangeSender", + "TableReader 124625374.88 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 124625374.88 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 124625374.88 mpp[tiflash] test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 124625374.88 mpp[tiflash] inner join, equal:[eq(test.t1.a, test.t2.a) eq(test.t3.b, test.t2.b)]", @@ -5524,7 +5524,7 @@ { "SQL": "select /*+ leading(t1, t2) */ * from t4 join t on t4.a=t.a left join t1 on t.a = t1.a join t2 on t.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24365.26 root data:ExchangeSender", + "TableReader 24365.26 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24365.26 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24365.26 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24365.26 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", @@ -5557,7 +5557,7 @@ { "SQL": "select /*+ leading(t2, t3) */ * from t4 join t on t4.a=t.a left join t1 on t.a = t1.a join t2 on t.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24365.26 root data:ExchangeSender", + "TableReader 24365.26 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24365.26 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24365.26 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24365.26 mpp[tiflash] left outer join, equal:[eq(test.t.a, test.t1.a)]", @@ -5588,7 +5588,7 @@ { "SQL": "select /*+ leading(t4, t3, t2, t, t1) */ * from t4 join t on t4.a=t.a left join t1 on t.a = t1.a join t2 on t.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24365.26 root data:ExchangeSender", + "TableReader 24365.26 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24365.26 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24365.26 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24365.26 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", @@ -5621,7 +5621,7 @@ { "SQL": "select /*+ leading(t4, t3, t2, t) */ * from t4 join t on t4.a=t.a left join t1 on t.a = t1.a join t2 on t.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24365.26 root data:ExchangeSender", + "TableReader 24365.26 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24365.26 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24365.26 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24365.26 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", @@ -5654,7 +5654,7 @@ { "SQL": "select /*+ leading(t3, t2, t) */ * from t4 join t on t4.a=t.a left join t1 on t.a = t1.a join t2 on t.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24365.26 root data:ExchangeSender", + "TableReader 24365.26 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24365.26 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24365.26 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24365.26 mpp[tiflash] left outer join, equal:[eq(test.t.a, test.t1.a)]", @@ -5685,14 +5685,14 @@ { "SQL": "select /*+ leading(t3) */ * from t2 left join (t1 left join t3 on t1.a=t3.a) on t2.b=t1.b;", "Plan": [ - "TableReader 15609.38 root data:ExchangeSender", + "TableReader 15609.38 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15609.38 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 12487.50 mpp[tiflash] ", - " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─HashJoin 12487.50 mpp[tiflash] left outer join, equal:[eq(test.t1.a, test.t3.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5706,14 +5706,14 @@ { "SQL": "select /*+ leading(t2, t1, t3) */ * from t2 left join (t1 left join t3 on t1.a=t3.a) on t2.b=t1.b;", "Plan": [ - "TableReader 15609.38 root data:ExchangeSender", + "TableReader 15609.38 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15609.38 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 12487.50 mpp[tiflash] ", - " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─HashJoin 12487.50 mpp[tiflash] left outer join, equal:[eq(test.t1.a, test.t3.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5730,14 +5730,14 @@ { "SQL": "select /*+ leading(t2, t3) */ * from t2 left join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b;", "Plan": [ - "TableReader 19492.21 root data:ExchangeSender", + "TableReader 19492.21 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 19492.21 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 19492.21 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15593.77 mpp[tiflash] ", - " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t3.b, test.t4.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5759,14 +5759,14 @@ { "SQL": "select /*+ leading(t3, t4) */ * from t2 left join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b;", "Plan": [ - "TableReader 19492.21 root data:ExchangeSender", + "TableReader 19492.21 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 19492.21 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 19492.21 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 10000.00 mpp[tiflash] ", - " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15593.77 mpp[tiflash] ", - " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t3.a, test.t1.a)]", " ├─ExchangeReceiver(Build) 9980.01 mpp[tiflash] ", @@ -5786,12 +5786,12 @@ { "SQL": "select /*+ leading(t3, t4) */ * from t2 left join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 30426.12 root data:ExchangeSender", + "TableReader 30426.12 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 30426.12 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 30426.12 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 30426.12 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 15593.77 mpp[tiflash] ", - " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t5.b, test.t6.b)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5805,7 +5805,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t2.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15593.77 mpp[tiflash] ", - " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─Projection 15593.77 mpp[tiflash] test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t3.a, test.t1.a)]", " ├─ExchangeReceiver(Build) 9980.01 mpp[tiflash] ", @@ -5825,12 +5825,12 @@ { "SQL": "select /*+ leading(t3, t4) leading(t5, t6) */ * from t2 left join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 30426.12 root data:ExchangeSender", + "TableReader 30426.12 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 30426.12 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 30426.12 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 30426.12 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 15593.77 mpp[tiflash] ", - " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t5.b, test.t6.b)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5844,7 +5844,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t2.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15593.77 mpp[tiflash] ", - " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t3.b, test.t4.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5865,12 +5865,12 @@ { "SQL": "select /*+ leading(t5, t6, t3, t4) */ * from t2 left join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 30426.12 root data:ExchangeSender", + "TableReader 30426.12 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 30426.12 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 30426.12 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 30426.12 mpp[tiflash] left outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 15593.77 mpp[tiflash] ", - " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t2.b, collate: binary]", + " │ └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t2.b, collate: binary]", " │ └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t5.b, test.t6.b)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5884,7 +5884,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t2.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15593.77 mpp[tiflash] ", - " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.b, collate: binary]", + " └─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.b, collate: binary]", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t3.b, test.t4.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5906,11 +5906,11 @@ { "SQL": "select /*+ leading(t1, t2) */ * from t4 join t on t4.a=t.a right join t1 on t.a = t1.a join t2 on t1.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24389.65 root data:ExchangeSender", + "TableReader 24389.65 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24389.65 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 24389.65 mpp[tiflash] right outer join, equal:[eq(test.t.a, test.t1.a)]", " ├─ExchangeReceiver(Build) 12487.50 mpp[tiflash] ", - " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t4.a, test.t.a)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5919,7 +5919,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15609.38 mpp[tiflash] ", - " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.a, collate: binary]", + " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.a, collate: binary]", " └─HashJoin 15609.38 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5938,12 +5938,12 @@ { "SQL": "select /*+ leading(t2, t3) */ * from t4 join t on t4.a=t.a right join t1 on t.a = t1.a join t2 on t1.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24389.65 root data:ExchangeSender", + "TableReader 24389.65 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24389.65 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 24389.65 mpp[tiflash] test.t4.a, test.t4.b, test.t.a, test.t.b, test.t1.a, test.t1.b, test.t2.a, test.t2.b, test.t3.a, test.t3.b", " └─HashJoin 24389.65 mpp[tiflash] right outer join, equal:[eq(test.t.a, test.t1.a)]", " ├─ExchangeReceiver(Build) 12487.50 mpp[tiflash] ", - " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t4.a, test.t.a)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5952,7 +5952,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15609.38 mpp[tiflash] ", - " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.a, collate: binary]", + " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.a, collate: binary]", " └─HashJoin 15609.38 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5971,11 +5971,11 @@ { "SQL": "select /*+ leading(t1, t3) */ * from t4 join t on t4.a=t.a right join t1 on t.a = t1.a join t2 on t1.b = t2.b join t3 on t2.b=t3.b;", "Plan": [ - "TableReader 24389.65 root data:ExchangeSender", + "TableReader 24389.65 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 24389.65 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 24389.65 mpp[tiflash] right outer join, equal:[eq(test.t.a, test.t1.a)]", " ├─ExchangeReceiver(Build) 12487.50 mpp[tiflash] ", - " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t4.a, test.t.a)]", " │ ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -5984,7 +5984,7 @@ " │ └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 15609.38 mpp[tiflash] ", - " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t1.a, collate: binary]", + " └─ExchangeSender 15609.38 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t1.a, collate: binary]", " └─HashJoin 15609.38 mpp[tiflash] inner join, equal:[eq(test.t2.b, test.t3.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: Broadcast", @@ -6005,7 +6005,7 @@ { "SQL": "select /*+ leading(t3) */ * from t2 right join (t1 left join t3 on t1.a=t3.a) on t2.b=t1.b;", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] right outer join, equal:[eq(test.t2.b, test.t1.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -6024,7 +6024,7 @@ { "SQL": "select /*+ leading(t2, t1, t3) */ * from t2 right join (t1 left join t3 on t1.a=t3.a) on t2.b=t1.b;", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] left outer join, equal:[eq(test.t1.a, test.t3.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -6043,7 +6043,7 @@ { "SQL": "select /*+ leading(t2, t3) */ * from t2 right join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b;", "Plan": [ - "TableReader 19492.21 root data:ExchangeSender", + "TableReader 19492.21 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 19492.21 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 19492.21 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b", " └─HashJoin 19492.21 mpp[tiflash] inner join, equal:[eq(test.t3.b, test.t4.b)]", @@ -6071,7 +6071,7 @@ { "SQL": "select /*+ leading(t3, t4) */ * from t2 right join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b;", "Plan": [ - "TableReader 19492.21 root data:ExchangeSender", + "TableReader 19492.21 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 19492.21 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 19492.21 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b", " └─HashJoin 19492.21 mpp[tiflash] right outer join, equal:[eq(test.t2.b, test.t1.b)]", @@ -6097,7 +6097,7 @@ { "SQL": "select /*+ leading(t3, t4) */ * from t2 right join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 30456.57 root data:ExchangeSender", + "TableReader 30456.57 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 30456.57 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 30456.57 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 30456.57 mpp[tiflash] inner join, equal:[eq(test.t5.b, test.t6.b)]", @@ -6133,7 +6133,7 @@ { "SQL": "select /*+ leading(t3, t4) leading(t5, t6) */ * from t2 right join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 30456.57 root data:ExchangeSender", + "TableReader 30456.57 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 30456.57 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 30456.57 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 30456.57 mpp[tiflash] inner join, equal:[eq(test.t5.b, test.t6.b)]", @@ -6171,7 +6171,7 @@ { "SQL": "select /*+ leading(t3, t4, t5, t6) */ * from t2 right join (t1 join t3 on t1.a=t3.a join t4 on t3.b = t4.b) on t2.b=t1.b join t5 on t2.a = t5.a join t6 on t5.b=t6.b;", "Plan": [ - "TableReader 243165526.37 root data:ExchangeSender", + "TableReader 243165526.37 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 243165526.37 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 243165526.37 mpp[tiflash] test.t2.a, test.t2.b, test.t1.a, test.t1.b, test.t3.a, test.t3.b, test.t4.a, test.t4.b, test.t5.a, test.t5.b, test.t6.a, test.t6.b", " └─HashJoin 243165526.37 mpp[tiflash] inner join, equal:[eq(test.t3.a, test.t1.a) eq(test.t2.b, test.t1.b)]", diff --git a/planner/core/testdata/plan_suite_out.json b/planner/core/testdata/plan_suite_out.json index 14213e2223dab..905ffab969200 100644 --- a/planner/core/testdata/plan_suite_out.json +++ b/planner/core/testdata/plan_suite_out.json @@ -5,14 +5,14 @@ { "SQL": "select /*+ MPP_1PHASE_AGG() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#11, funcs:sum(Column#8)->Column#5, funcs:firstrow(Column#9)->test.t.a", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.a, test.t.c", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warn": null @@ -20,13 +20,13 @@ { "SQL": "select /*+ MPP_2PHASE_AGG() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.c, funcs:sum(Column#10)->Column#5, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, Column#14, funcs:sum(Column#12)->Column#10", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#12, test.t.a, test.t.c", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -36,15 +36,15 @@ { "SQL": "select /*+ shuffle_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ], @@ -53,7 +53,7 @@ { "SQL": "select /*+ broadcast_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -68,14 +68,14 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_1PHASE_AGG() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#11, funcs:sum(Column#8)->Column#5, funcs:firstrow(Column#9)->test.t.a", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.a, test.t.c", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warn": null @@ -83,13 +83,13 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_2PHASE_AGG() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.c, funcs:sum(Column#10)->Column#5, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, Column#14, funcs:sum(Column#12)->Column#10", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#12, test.t.a, test.t.c", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -99,15 +99,15 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ], @@ -116,7 +116,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -131,7 +131,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2), hash_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -148,7 +148,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2), hash_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -165,7 +165,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2), hash_join_build(t1) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -182,7 +182,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2), hash_join_build(t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -199,7 +199,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2), hash_join_probe(t1) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -216,7 +216,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2), hash_join_probe(t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -233,7 +233,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2), merge_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -250,7 +250,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2), merge_join(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -267,7 +267,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), shuffle_join(t1, t2), INL_JOIN(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -284,7 +284,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2]), broadcast_join(t1, t2), INL_JOIN(t1, t2) */ * from t t1, t t2 where t1.a=t2.a", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -301,14 +301,14 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_1PHASE_AGG(), hash_agg() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#11, funcs:sum(Column#8)->Column#5, funcs:firstrow(Column#9)->test.t.a", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.a, test.t.c", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warn": null @@ -316,13 +316,13 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_2PHASE_AGG(), stream_agg() */ a, sum(b) from t group by a, c", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.c, funcs:sum(Column#6)->Column#5, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#9, funcs:sum(Column#8)->Column#6", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.c", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -347,14 +347,14 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_1PHASE_AGG(), ignore_index(t, idx_a) */ a, sum(b) from t where a > 1 group by a, c", "Plan": [ - "TableReader 2666.67 root data:ExchangeSender", + "TableReader 2666.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 2666.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 2666.67 mpp[tiflash] test.t.a, Column#5", " └─Projection 2666.67 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 2666.67 mpp[tiflash] group by:Column#10, Column#11, funcs:sum(Column#8)->Column#5, funcs:firstrow(Column#9)->test.t.a", " └─Projection 3333.33 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.a, test.t.c", " └─ExchangeReceiver 3333.33 mpp[tiflash] ", - " └─ExchangeSender 3333.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 3333.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─Selection 3333.33 mpp[tiflash] gt(test.t.a, 1)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -378,13 +378,13 @@ { "SQL": "select /*+ read_from_storage(tiflash[t]), MPP_2PHASE_AGG(), index_merge(t, idx_b, idx_a) */ a, sum(b) from t where b < 2 or a > 2 group by a, c", "Plan": [ - "TableReader 4439.11 root data:ExchangeSender", + "TableReader 4439.11 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 4439.11 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 4439.11 mpp[tiflash] test.t.a, Column#5", " └─Projection 4439.11 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 4439.11 mpp[tiflash] group by:test.t.a, test.t.c, funcs:sum(Column#13)->Column#5, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 4439.11 mpp[tiflash] ", - " └─ExchangeSender 4439.11 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 4439.11 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg 4439.11 mpp[tiflash] group by:Column#16, Column#17, funcs:sum(Column#15)->Column#13", " └─Projection 5548.89 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#15, test.t.a, test.t.c", " └─Selection 5548.89 mpp[tiflash] or(lt(test.t.b, 2), gt(test.t.a, 2))", @@ -397,22 +397,22 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2, t3]), shuffle_join(t1, t2, t3), straight_join() */ * from t t1, t t2, t t3 where t1.a=t2.a and t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.b))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t3 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 12475.01 mpp[tiflash] ", - " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─HashJoin 12475.01 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9980.01 mpp[tiflash] ", - " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.a)), not(isnull(test.t.b))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ], @@ -421,22 +421,22 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2, t3]), shuffle_join(t1, t2, t3), leading(t3, t1) */ * from t t1, t t2, t t3 where t1.a=t2.a and t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.b))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t3 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 12475.01 mpp[tiflash] ", - " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 12475.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─HashJoin 12475.01 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9980.01 mpp[tiflash] ", - " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 9980.01 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 9980.01 mpp[tiflash] not(isnull(test.t.a)), not(isnull(test.t.b))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ], @@ -448,7 +448,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2, t3]), broadcast_join(t1, t2, t3), straight_join() */ * from t t2, t t1, t t3 where t1.a=t2.a and t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -468,7 +468,7 @@ { "SQL": "select /*+ read_from_storage(tiflash[t1, t2, t3]), broadcast_join(t1, t2, t3), leading(t2, t3) */ * from t t1, t t2, t t3 where t1.a=t2.a and t2.b=t3.b", "Plan": [ - "TableReader 15593.77 root data:ExchangeSender", + "TableReader 15593.77 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 15593.77 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 15593.77 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -491,14 +491,14 @@ { "SQL": "select /*+ qb_name(qb, v), MPP_1PHASE_AGG(@qb) */ * from v", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#10, Column#11, funcs:sum(Column#8)->Column#5, funcs:firstrow(Column#9)->test.t.a", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#8, test.t.a, test.t.a, test.t.c", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warn": null @@ -506,13 +506,13 @@ { "SQL": "select /*+ qb_name(qb, v), MPP_2PHASE_AGG(@qb) */ * from v", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#5", " └─Projection 8000.00 mpp[tiflash] Column#5, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, test.t.c, funcs:sum(Column#10)->Column#5, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary], [name: test.t.c, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, Column#14, funcs:sum(Column#12)->Column#10", " └─Projection 10000.00 mpp[tiflash] cast(test.t.b, decimal(10,0) BINARY)->Column#12, test.t.a, test.t.c", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -522,16 +522,16 @@ { "SQL": "select /*+ qb_name(qb, v1), shuffle_join(t1@qb, t2@qb) */ * from v1", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12487.50 mpp[tiflash] test.t.a", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo" ], @@ -540,7 +540,7 @@ { "SQL": "select /*+ qb_name(qb, v1), broadcast_join(t1@qb, t2@qb) */ * from v1", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12487.50 mpp[tiflash] test.t.a", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", @@ -556,7 +556,7 @@ { "SQL": "SELECT /*+ shuffle_join(t) */ * FROM t WHERE EXISTS (SELECT /*+ SEMI_JOIN_REWRITE */ 1 FROM t t1 WHERE t1.b = t.b);", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -574,7 +574,7 @@ { "SQL": "SELECT /*+ broadcast_join(t) */ * FROM t WHERE EXISTS (SELECT /*+ SEMI_JOIN_REWRITE */ 1 FROM t t1 WHERE t1.b = t.b);", "Plan": [ - "TableReader 7992.00 root data:ExchangeSender", + "TableReader 7992.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 7992.00 mpp[tiflash] semi join, equal:[eq(test.t.b, test.t.b)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -592,7 +592,7 @@ { "SQL": "select * from t t1 where t1.a < (select /*+ MPP_1PHASE_AGG() */ sum(t2.a) from t t2 where t2.b = t1.b);", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 9990.00 mpp[tiflash] test.t.a, test.t.b, test.t.c", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)], other cond:lt(cast(test.t.a, decimal(10,0) BINARY), Column#9)", @@ -602,7 +602,7 @@ " │ └─HashAgg 7992.00 mpp[tiflash] group by:Column#26, funcs:sum(Column#24)->Column#9, funcs:firstrow(Column#25)->test.t.b", " │ └─Projection 9990.00 mpp[tiflash] cast(test.t.a, decimal(10,0) BINARY)->Column#24, test.t.b, test.t.b", " │ └─ExchangeReceiver 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.b))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t2 keep order:false, stats:pseudo", " └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.t.b))", @@ -613,7 +613,7 @@ { "SQL": "select * from t t1 where t1.a < (select /*+ MPP_2PHASE_AGG() */ sum(t2.a) from t t2 where t2.b = t1.b);", "Plan": [ - "TableReader 9990.00 root data:ExchangeSender", + "TableReader 9990.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 9990.00 mpp[tiflash] test.t.a, test.t.b, test.t.c", " └─HashJoin 9990.00 mpp[tiflash] inner join, equal:[eq(test.t.b, test.t.b)], other cond:lt(cast(test.t.a, decimal(10,0) BINARY), Column#9)", @@ -622,7 +622,7 @@ " │ └─Projection 7992.00 mpp[tiflash] Column#9, test.t.b", " │ └─HashAgg 7992.00 mpp[tiflash] group by:test.t.b, funcs:sum(Column#13)->Column#9, funcs:firstrow(test.t.b)->test.t.b", " │ └─ExchangeReceiver 7992.00 mpp[tiflash] ", - " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 7992.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─HashAgg 7992.00 mpp[tiflash] group by:Column#29, funcs:sum(Column#28)->Column#13", " │ └─Projection 9990.00 mpp[tiflash] cast(test.t.a, decimal(10,0) BINARY)->Column#28, test.t.b", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.b))", @@ -642,13 +642,13 @@ " └─Selection 1701.55 root gt(test.t.b, 1)", " └─CTEFullScan 2126.93 root CTE:cte data:CTE_0", "CTE_0 2126.93 root Non-Recursive CTE", - "└─TableReader(Seed Part) 2126.93 root data:ExchangeSender", + "└─TableReader(Seed Part) 2126.93 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2126.93 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 2126.93 mpp[tiflash] or(lt(Column#5, 18), gt(test.t.b, 1))", " └─Projection 2658.67 mpp[tiflash] Column#5, test.t.b", " └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#5, funcs:firstrow(test.t.b)->test.t.b", " └─ExchangeReceiver 3323.33 mpp[tiflash] ", - " └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 60)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -664,13 +664,13 @@ " └─Selection 1701.55 root gt(test.t.b, 1)", " └─CTEFullScan 2126.93 root CTE:cte data:CTE_0", "CTE_0 2126.93 root Non-Recursive CTE", - "└─TableReader(Seed Part) 2126.93 root data:ExchangeSender", + "└─TableReader(Seed Part) 2126.93 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 2126.93 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 2126.93 mpp[tiflash] or(lt(Column#5, 18), gt(test.t.b, 1))", " └─Projection 2658.67 mpp[tiflash] Column#5, test.t.b", " └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:sum(Column#22)->Column#5, funcs:firstrow(test.t.b)->test.t.b", " └─ExchangeReceiver 2658.67 mpp[tiflash] ", - " └─ExchangeSender 2658.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 2658.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#22", " └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 60)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -687,16 +687,16 @@ " └─Selection 5543.34 root gt(test.t.b, 1)", " └─CTEFullScan 6929.18 root CTE:cte data:CTE_0", "CTE_0 6929.18 root Non-Recursive CTE", - "└─TableReader(Seed Part) 6929.18 root data:ExchangeSender", + "└─TableReader(Seed Part) 6929.18 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6929.18 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 6929.18 mpp[tiflash] test.t.a, test.t.b", " └─HashJoin 6929.18 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)], other cond:or(lt(test.t.a, 18), gt(test.t.b, 1))", " ├─ExchangeReceiver(Build) 5543.34 mpp[tiflash] ", - " │ └─ExchangeSender 5543.34 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 5543.34 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 5543.34 mpp[tiflash] not(isnull(test.t.a)), or(lt(test.t.a, 18), gt(test.t.b, 1))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ], @@ -712,7 +712,7 @@ " └─Selection 5543.34 root gt(test.t.b, 1)", " └─CTEFullScan 6929.18 root CTE:cte data:CTE_0", "CTE_0 6929.18 root Non-Recursive CTE", - "└─TableReader(Seed Part) 6929.18 root data:ExchangeSender", + "└─TableReader(Seed Part) 6929.18 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 6929.18 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 6929.18 mpp[tiflash] test.t.a, test.t.b", " └─HashJoin 6929.18 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)], other cond:or(lt(test.t.a, 18), gt(test.t.b, 1))", @@ -728,26 +728,26 @@ { "SQL": "WITH CTE AS (SELECT /*+ MERGE(), MPP_1PHASE_AGG() */ count(*) as a, b FROM t WHERE t.a < 60 group by b) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ - "TableReader 3013.16 root data:ExchangeSender", + "TableReader 3013.16 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 3013.16 mpp[tiflash] Column#20, Column#21", " └─HashAgg 3013.16 mpp[tiflash] group by:Column#20, Column#21, funcs:firstrow(Column#20)->Column#20, funcs:firstrow(Column#21)->Column#21", " └─ExchangeReceiver 3013.16 mpp[tiflash] ", - " └─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#20, collate: binary], [name: Column#21, collate: binary]", + " └─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#20, collate: binary], [name: Column#21, collate: binary]", " └─Union 3013.16 mpp[tiflash] ", " ├─Projection 2126.93 mpp[tiflash] cast(Column#12, bigint(21) BINARY)->Column#20, test.t.b", " │ └─Selection 2126.93 mpp[tiflash] lt(Column#12, 18)", " │ └─Projection 2658.67 mpp[tiflash] Column#12, test.t.b", " │ └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#12, funcs:firstrow(test.t.b)->test.t.b", " │ └─ExchangeReceiver 3323.33 mpp[tiflash] ", - " │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 60)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─Projection 886.22 mpp[tiflash] cast(Column#20, bigint(21) BINARY)->Column#20, Column#21", " └─Projection 886.22 mpp[tiflash] Column#19, test.t.b", " └─HashAgg 886.22 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#19, funcs:firstrow(test.t.b)->test.t.b", " └─ExchangeReceiver 1107.78 mpp[tiflash] ", - " └─ExchangeSender 1107.78 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 1107.78 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─Selection 1107.78 mpp[tiflash] gt(test.t.b, 1), lt(test.t.a, 60)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], @@ -756,19 +756,19 @@ { "SQL": "WITH CTE AS (SELECT /*+ MERGE(), MPP_2PHASE_AGG() */ count(*) as a, b FROM t WHERE t.a < 60 group by b) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ - "TableReader 3013.16 root data:ExchangeSender", + "TableReader 3013.16 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 3013.16 mpp[tiflash] Column#20, Column#21", " └─HashAgg 3013.16 mpp[tiflash] group by:Column#20, Column#21, funcs:firstrow(Column#20)->Column#20, funcs:firstrow(Column#21)->Column#21", " └─ExchangeReceiver 3013.16 mpp[tiflash] ", - " └─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#20, collate: binary], [name: Column#21, collate: binary]", + " └─ExchangeSender 3013.16 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#20, collate: binary], [name: Column#21, collate: binary]", " └─Union 3013.16 mpp[tiflash] ", " ├─Projection 2126.93 mpp[tiflash] cast(Column#12, bigint(21) BINARY)->Column#20, test.t.b", " │ └─Selection 2126.93 mpp[tiflash] lt(Column#12, 18)", " │ └─Projection 2658.67 mpp[tiflash] Column#12, test.t.b", " │ └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:sum(Column#32)->Column#12, funcs:firstrow(test.t.b)->test.t.b", " │ └─ExchangeReceiver 2658.67 mpp[tiflash] ", - " │ └─ExchangeSender 2658.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " │ └─ExchangeSender 2658.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " │ └─HashAgg 2658.67 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#32", " │ └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 60)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -776,7 +776,7 @@ " └─Projection 886.22 mpp[tiflash] Column#19, test.t.b", " └─HashAgg 886.22 mpp[tiflash] group by:test.t.b, funcs:sum(Column#46)->Column#19, funcs:firstrow(test.t.b)->test.t.b", " └─ExchangeReceiver 886.22 mpp[tiflash] ", - " └─ExchangeSender 886.22 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.b, collate: binary]", + " └─ExchangeSender 886.22 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.b, collate: binary]", " └─HashAgg 886.22 mpp[tiflash] group by:test.t.b, funcs:count(1)->Column#46", " └─Selection 1107.78 mpp[tiflash] gt(test.t.b, 1), lt(test.t.a, 60)", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -786,32 +786,32 @@ { "SQL": "WITH CTE AS (SELECT /*+ MERGE(), shuffle_join(t1, t) */ t.a, t.b FROM t join t t1 where t.a = t1.a) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ - "TableReader 5322.67 root data:ExchangeSender", + "TableReader 5322.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 5322.67 mpp[tiflash] Column#29, Column#30", " └─HashAgg 5322.67 mpp[tiflash] group by:Column#29, Column#30, funcs:firstrow(Column#29)->Column#29, funcs:firstrow(Column#30)->Column#30", " └─ExchangeReceiver 5322.67 mpp[tiflash] ", - " └─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#29, collate: binary], [name: Column#30, collate: binary]", + " └─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#29, collate: binary], [name: Column#30, collate: binary]", " └─HashAgg 5322.67 mpp[tiflash] group by:Column#29, Column#30, ", " └─Union 8316.67 mpp[tiflash] ", " ├─Projection 4154.17 mpp[tiflash] test.t.a, test.t.b", " │ └─HashJoin 4154.17 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " │ ├─ExchangeReceiver(Build) 3323.33 mpp[tiflash] ", - " │ │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ │ └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 18), not(isnull(test.t.a))", " │ │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " │ └─ExchangeReceiver(Probe) 3323.33 mpp[tiflash] ", - " │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 3323.33 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 3323.33 mpp[tiflash] lt(test.t.a, 18), not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo", " └─Projection 4162.50 mpp[tiflash] test.t.a, test.t.b", " └─HashJoin 4162.50 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.a)]", " ├─ExchangeReceiver(Build) 3330.00 mpp[tiflash] ", - " │ └─ExchangeSender 3330.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " │ └─ExchangeSender 3330.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " │ └─Selection 3330.00 mpp[tiflash] gt(test.t.b, 1), not(isnull(test.t.a))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.t.a))", " └─TableFullScan 10000.00 mpp[tiflash] table:t1 keep order:false, stats:pseudo" ], @@ -823,12 +823,12 @@ { "SQL": "WITH CTE AS (SELECT /*+ MERGE(), broadcast_join(t1, t) */ t.a, t.b FROM t join t t1 where t.a = t1.a) SELECT * FROM CTE WHERE CTE.a <18 union select * from cte where cte.b > 1;", "Plan": [ - "TableReader 5322.67 root data:ExchangeSender", + "TableReader 5322.67 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 5322.67 mpp[tiflash] Column#29, Column#30", " └─HashAgg 5322.67 mpp[tiflash] group by:Column#29, Column#30, funcs:firstrow(Column#29)->Column#29, funcs:firstrow(Column#30)->Column#30", " └─ExchangeReceiver 5322.67 mpp[tiflash] ", - " └─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#29, collate: binary], [name: Column#30, collate: binary]", + " └─ExchangeSender 5322.67 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#29, collate: binary], [name: Column#30, collate: binary]", " └─HashAgg 5322.67 mpp[tiflash] group by:Column#29, Column#30, ", " └─Union 8316.67 mpp[tiflash] ", " ├─Projection 4154.17 mpp[tiflash] test.t.a, test.t.b", @@ -4195,7 +4195,7 @@ { "SQL": "select * from employee where deptid>1", "Plan": [ - "TableReader 3333.33 root data:ExchangeSender", + "TableReader 3333.33 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3333.33 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 3333.33 mpp[tiflash] gt(test.employee.deptid, 1)", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" @@ -4204,7 +4204,7 @@ { "SQL": "select deptid+5, empid*10 from employee where deptid>1", "Plan": [ - "TableReader 3333.33 root data:ExchangeSender", + "TableReader 3333.33 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 3333.33 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 3333.33 mpp[tiflash] plus(test.employee.deptid, 5)->Column#5, mul(test.employee.empid, 10)->Column#6", " └─Selection 3333.33 mpp[tiflash] gt(test.employee.deptid, 1)", @@ -4214,12 +4214,12 @@ { "SQL": "select count(*) from employee group by deptid+1", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#5", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#12, funcs:sum(Column#13)->Column#5", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#12, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#12, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#14, funcs:count(1)->Column#13", " └─Projection 10000.00 mpp[tiflash] plus(test.employee.deptid, 1)->Column#14", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" @@ -4228,7 +4228,7 @@ { "SQL": "select count(distinct deptid) a from employee", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#7)->Column#5", @@ -4236,7 +4236,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#7", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ] @@ -4244,7 +4244,7 @@ { "SQL": "select * from employee join employee e1 using(deptid)", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 12487.50 mpp[tiflash] test.employee.deptid, test.employee.empid, test.employee.salary, test.employee.empid, test.employee.salary", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, test.employee.deptid)]", @@ -4259,7 +4259,7 @@ { "SQL": "select count(distinct a) from (select count(distinct deptid) a from employee) x", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#6", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct Column#5)->Column#6", @@ -4269,7 +4269,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#8", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ] @@ -4277,12 +4277,12 @@ { "SQL": "select count(a) from (select count(distinct deptid) a, count(distinct empid) b from employee) x group by b+1", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#7", " └─HashAgg 1.00 mpp[tiflash] group by:Column#12, funcs:sum(Column#13)->Column#7", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#12, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#12, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:Column#15, funcs:count(Column#14)->Column#13", " └─Projection 1.00 mpp[tiflash] Column#5, plus(Column#6, 1)->Column#15", " └─Projection 1.00 mpp[tiflash] Column#5, Column#6", @@ -4296,7 +4296,7 @@ { "SQL": "select count(a) from (select count(distinct deptid) a, count(distinct empid) b from employee) x group by b", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#7", " └─HashAgg 1.00 mpp[tiflash] group by:Column#6, funcs:count(Column#5)->Column#7", @@ -4311,7 +4311,7 @@ { "SQL": "select * from employee join (select count(distinct deptid) a, count(distinct empid) b from employee) e1", "Plan": [ - "TableReader 10000.00 root data:ExchangeSender", + "TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 10000.00 mpp[tiflash] CARTESIAN inner join", " ├─ExchangeReceiver(Build) 1.00 mpp[tiflash] ", @@ -4328,7 +4328,7 @@ { "SQL": "select * from employee e1 join (select count(distinct deptid) a from employee) e2 on e1.deptid = e2.a", "Plan": [ - "TableReader 1.25 root data:ExchangeSender", + "TableReader 1.25 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.25 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 1.25 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#9)]", " ├─ExchangeReceiver(Build) 1.00 mpp[tiflash] ", @@ -4339,7 +4339,7 @@ " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#10", " │ └─ExchangeReceiver 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " │ └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", @@ -4349,7 +4349,7 @@ { "SQL": "select * from (select count(distinct deptid) a from employee) e1 join employee e2 on e1.a = e2.deptid", "Plan": [ - "TableReader 1.25 root data:ExchangeSender", + "TableReader 1.25 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.25 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.25 mpp[tiflash] Column#5, test.employee.empid, test.employee.deptid, test.employee.salary", " └─HashJoin 1.25 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#5)]", @@ -4361,7 +4361,7 @@ " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#10", " │ └─ExchangeReceiver 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " │ └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─Selection(Probe) 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", @@ -4371,7 +4371,7 @@ { "SQL": "select * from (select count(distinct deptid) a from employee) e1 join (select count(distinct deptid) b from employee) e2 on e1.a=e2.b", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 1.00 mpp[tiflash] inner join, equal:[eq(Column#5, Column#10)]", " ├─ExchangeReceiver(Build) 1.00 mpp[tiflash] ", @@ -4382,7 +4382,7 @@ " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#11", " │ └─ExchangeReceiver 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " │ └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─Projection(Probe) 1.00 mpp[tiflash] Column#10", @@ -4391,7 +4391,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#12", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ] @@ -4399,7 +4399,7 @@ { "SQL": "select * from employee e1 join employee e2 on e1.deptid = e2.deptid", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, test.employee.deptid)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", @@ -4413,7 +4413,7 @@ { "SQL": "select * from (select deptid+1 d, count(empid) a from employee group by d) e1 join employee e2 on e1.d = e2.deptid", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#6, Column#5, test.employee.empid, test.employee.deptid, test.employee.salary", " └─HashJoin 8000.00 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#6)]", @@ -4424,7 +4424,7 @@ " │ └─Projection 8000.00 mpp[tiflash] Column#5, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:sum(Column#14)->Column#5, funcs:firstrow(Column#15)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#13, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#13, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#27, funcs:count(Column#25)->Column#14, funcs:firstrow(Column#26)->Column#15", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#27", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", @@ -4435,7 +4435,7 @@ { "SQL": "select * from employee e1 join (select deptid+1 d, count(empid) a from employee group by d) e2 on e1.deptid = e2.d", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 8000.00 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#10)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", @@ -4445,7 +4445,7 @@ " │ └─Projection 8000.00 mpp[tiflash] Column#9, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:sum(Column#14)->Column#9, funcs:firstrow(Column#15)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#13, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#13, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#27, funcs:count(Column#25)->Column#14, funcs:firstrow(Column#26)->Column#15", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#27", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", @@ -4456,7 +4456,7 @@ { "SQL": "select * from (select deptid+1 d, count(empid) a from employee group by d) e1 join (select deptid+1 d, count(empid) a from employee group by d) e2 on e1.d = e2.d", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6400.00 mpp[tiflash] inner join, equal:[eq(Column#6, Column#12)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", @@ -4466,7 +4466,7 @@ " │ └─Projection 8000.00 mpp[tiflash] Column#5, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#17, funcs:sum(Column#18)->Column#5, funcs:firstrow(Column#19)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#17, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#17, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#43, funcs:count(Column#41)->Column#18, funcs:firstrow(Column#42)->Column#19", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#43", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", @@ -4475,7 +4475,7 @@ " └─Projection 8000.00 mpp[tiflash] Column#11, test.employee.deptid", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#20, funcs:sum(Column#21)->Column#11, funcs:firstrow(Column#22)->test.employee.deptid", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#20, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#20, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#46, funcs:count(Column#44)->Column#21, funcs:firstrow(Column#45)->Column#22", " └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#46", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" @@ -4494,7 +4494,7 @@ "Plan": [ "Projection 1.25 root Column#5, test.employee.empid, test.employee.deptid, test.employee.salary", "└─HashJoin 1.25 root inner join, equal:[eq(test.employee.deptid, Column#5)]", - " ├─TableReader(Build) 1.00 root data:ExchangeSender", + " ├─TableReader(Build) 1.00 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─Projection 1.00 mpp[tiflash] Column#5", " │ └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#12)->Column#5", @@ -4502,7 +4502,7 @@ " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#12", " │ └─ExchangeReceiver 1.00 mpp[tiflash] ", - " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " │ └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─TableReader(Probe) 9990.00 root data:Selection", @@ -4514,7 +4514,7 @@ "SQL": "select * from (select count(distinct deptid) a from employee) e1 join (select count(distinct deptid) b from employee) e2 on e1.a=e2.b", "Plan": [ "HashJoin 1.00 root inner join, equal:[eq(Column#5, Column#10)]", - "├─TableReader(Build) 1.00 root data:ExchangeSender", + "├─TableReader(Build) 1.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─Projection 1.00 mpp[tiflash] Column#10", "│ └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#16)->Column#10", @@ -4522,10 +4522,10 @@ "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#16", "│ └─ExchangeReceiver 1.00 mpp[tiflash] ", - "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", "│ └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", "│ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", - "└─TableReader(Probe) 1.00 root data:ExchangeSender", + "└─TableReader(Probe) 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#5", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#15)->Column#5", @@ -4533,7 +4533,7 @@ " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct test.employee.deptid)->Column#15", " └─ExchangeReceiver 1.00 mpp[tiflash] ", - " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg 1.00 mpp[tiflash] group by:test.employee.deptid, ", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ] @@ -4541,15 +4541,15 @@ { "SQL": "select * from employee e1 join employee e2 on e1.deptid = e2.deptid", "Plan": [ - "TableReader 12487.50 root data:ExchangeSender", + "TableReader 12487.50 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 12487.50 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 12487.50 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, test.employee.deptid)]", " ├─ExchangeReceiver(Build) 9990.00 mpp[tiflash] ", - " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " │ └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " │ └─Selection 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:e1 keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", " └─TableFullScan 10000.00 mpp[tiflash] table:e2 keep order:false, stats:pseudo" ] @@ -4557,23 +4557,23 @@ { "SQL": "select * from (select deptid+1 d, count(empid) a from employee group by d) e1 join employee e2 on e1.d = e2.deptid", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] Column#6, Column#5, test.employee.empid, test.employee.deptid, test.employee.salary", " └─HashJoin 8000.00 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#6)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", - " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#6, collate: binary]", + " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#6, collate: binary]", " │ └─Projection 6400.00 mpp[tiflash] plus(test.employee.deptid, 1)->Column#6, Column#5", " │ └─Selection 6400.00 mpp[tiflash] not(isnull(plus(test.employee.deptid, 1)))", " │ └─Projection 8000.00 mpp[tiflash] Column#5, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:sum(Column#14)->Column#5, funcs:firstrow(Column#15)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#13, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#13, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#29, funcs:count(Column#27)->Column#14, funcs:firstrow(Column#28)->Column#15", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#29", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#26, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#26, collate: binary]", " └─Projection 9990.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, cast(test.employee.deptid, bigint(20))->Column#26", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", " └─TableFullScan 10000.00 mpp[tiflash] table:e2 keep order:false, stats:pseudo" @@ -4582,23 +4582,23 @@ { "SQL": "select * from employee e1 join (select deptid+1 d, count(empid) a from employee group by d) e2 on e1.deptid = e2.d", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, Column#10, Column#9", " └─HashJoin 8000.00 mpp[tiflash] inner join, equal:[eq(test.employee.deptid, Column#10)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", - " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#10, collate: binary]", + " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#10, collate: binary]", " │ └─Projection 6400.00 mpp[tiflash] plus(test.employee.deptid, 1)->Column#10, Column#9", " │ └─Selection 6400.00 mpp[tiflash] not(isnull(plus(test.employee.deptid, 1)))", " │ └─Projection 8000.00 mpp[tiflash] Column#9, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#13, funcs:sum(Column#14)->Column#9, funcs:firstrow(Column#15)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#13, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#13, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#29, funcs:count(Column#27)->Column#14, funcs:firstrow(Column#28)->Column#15", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#29", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 9990.00 mpp[tiflash] ", - " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#26, collate: binary]", + " └─ExchangeSender 9990.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#26, collate: binary]", " └─Projection 9990.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, cast(test.employee.deptid, bigint(20))->Column#26", " └─Selection 9990.00 mpp[tiflash] not(isnull(test.employee.deptid))", " └─TableFullScan 10000.00 mpp[tiflash] table:e1 keep order:false, stats:pseudo" @@ -4607,28 +4607,28 @@ { "SQL": "select * from (select deptid+1 d, count(empid) a from employee group by d) e1 join (select deptid+1 d, count(empid) a from employee group by d) e2 on e1.d = e2.d", "Plan": [ - "TableReader 6400.00 root data:ExchangeSender", + "TableReader 6400.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashJoin 6400.00 mpp[tiflash] inner join, equal:[eq(Column#6, Column#12)]", " ├─ExchangeReceiver(Build) 6400.00 mpp[tiflash] ", - " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#6, collate: binary]", + " │ └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#6, collate: binary]", " │ └─Projection 6400.00 mpp[tiflash] plus(test.employee.deptid, 1)->Column#6, Column#5", " │ └─Selection 6400.00 mpp[tiflash] not(isnull(plus(test.employee.deptid, 1)))", " │ └─Projection 8000.00 mpp[tiflash] Column#5, test.employee.deptid", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#17, funcs:sum(Column#18)->Column#5, funcs:firstrow(Column#19)->test.employee.deptid", " │ └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#17, collate: binary]", + " │ └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#17, collate: binary]", " │ └─HashAgg 8000.00 mpp[tiflash] group by:Column#43, funcs:count(Column#41)->Column#18, funcs:firstrow(Column#42)->Column#19", " │ └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#43", " │ └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo", " └─ExchangeReceiver(Probe) 6400.00 mpp[tiflash] ", - " └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#12, collate: binary]", + " └─ExchangeSender 6400.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#12, collate: binary]", " └─Projection 6400.00 mpp[tiflash] plus(test.employee.deptid, 1)->Column#12, Column#11", " └─Selection 6400.00 mpp[tiflash] not(isnull(plus(test.employee.deptid, 1)))", " └─Projection 8000.00 mpp[tiflash] Column#11, test.employee.deptid", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#20, funcs:sum(Column#21)->Column#11, funcs:firstrow(Column#22)->test.employee.deptid", " └─ExchangeReceiver 8000.00 mpp[tiflash] ", - " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#20, collate: binary]", + " └─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#20, collate: binary]", " └─HashAgg 8000.00 mpp[tiflash] group by:Column#46, funcs:count(Column#44)->Column#21, funcs:firstrow(Column#45)->Column#22", " └─Projection 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, plus(test.employee.deptid, 1)->Column#46", " └─TableFullScan 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" @@ -7363,7 +7363,7 @@ "SQL": "select count(*) from t", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#10", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t.d)->Column#12", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7374,7 +7374,7 @@ "SQL": "select count(1), count(3.1415), count(0), count(null) from t -- every count but count(null) can be rewritten", "Plan": [ "HashAgg 1.00 root funcs:count(Column#18)->Column#10, funcs:count(Column#19)->Column#11, funcs:count(Column#20)->Column#12, funcs:count(Column#21)->Column#13", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t.d)->Column#18, funcs:count(test.t.d)->Column#19, funcs:count(test.t.d)->Column#20, funcs:count(NULL)->Column#21", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7385,7 +7385,7 @@ "SQL": "select count(*) from t where a=1", "Plan": [ "HashAgg 1.00 root funcs:count(Column#12)->Column#10", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#12", " └─Selection 10.00 mpp[tiflash] eq(test.t.a, 1)", @@ -7397,7 +7397,7 @@ "SQL": "select count(*) from t_pick_row_id", "Plan": [ "HashAgg 1.00 root funcs:count(Column#5)->Column#3", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t_pick_row_id._tidb_rowid)->Column#5", " └─TableFullScan 10000.00 mpp[tiflash] table:t_pick_row_id keep order:false, stats:pseudo" @@ -7409,7 +7409,7 @@ "Plan": [ "HashJoin 1.25 root inner join, equal:[eq(test.t.a, Column#10)]", "├─HashAgg(Build) 1.00 root funcs:count(Column#22)->Column#10", - "│ └─TableReader 1.00 root data:ExchangeSender", + "│ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "│ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", "│ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.t.d)->Column#22", "│ └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo", @@ -7426,7 +7426,7 @@ " ├─TableReader(Build) 10000.00 root data:TableFullScan", " │ └─TableFullScan 10000.00 cop[tiflash] table:out keep order:false, stats:pseudo", " └─HashAgg(Probe) 10000.00 root funcs:count(Column#21)->Column#19", - " └─TableReader 10000.00 root data:ExchangeSender", + " └─TableReader 10000.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 10000.00 mpp[tiflash] funcs:count(1)->Column#21", " └─Selection 80000000.00 mpp[tiflash] eq(cast(test.t.a, double BINARY), cast(test.t.b, double BINARY))", @@ -7438,7 +7438,7 @@ "SQL": "select count(*) from t t1, t t2 where t1.a=t2.e -- shouldn't be rewritten when join under agg", "Plan": [ "HashAgg 1.00 root funcs:count(Column#20)->Column#19", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#20", " └─HashJoin 12500.00 mpp[tiflash] inner join, equal:[eq(test.t.a, test.t.e)]", @@ -7452,7 +7452,7 @@ { "SQL": "select count(distinct 1) from t -- shouldn't be rewritten", "Plan": [ - "TableReader 1.00 root data:ExchangeSender", + "TableReader 1.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 1.00 mpp[tiflash] Column#10", " └─HashAgg 1.00 mpp[tiflash] funcs:count(distinct Column#12)->Column#10", @@ -7467,7 +7467,7 @@ "SQL": "select count(1), count(a), count(b) from t -- keep count(1)", "Plan": [ "HashAgg 1.00 root funcs:count(Column#16)->Column#10, funcs:count(Column#17)->Column#11, funcs:count(Column#18)->Column#12", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(1)->Column#16, funcs:count(test.t.a)->Column#17, funcs:count(test.t.b)->Column#18", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" @@ -7477,13 +7477,13 @@ { "SQL": "select a, count(*) from t group by a -- shouldn't be rewritten", "Plan": [ - "TableReader 8000.00 root data:ExchangeSender", + "TableReader 8000.00 root MppVersion: 1, data:ExchangeSender", "└─ExchangeSender 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection 8000.00 mpp[tiflash] test.t.a, Column#10", " └─Projection 8000.00 mpp[tiflash] Column#10, test.t.a", " └─HashAgg 8000.00 mpp[tiflash] group by:test.t.a, funcs:count(1)->Column#10, funcs:firstrow(test.t.a)->test.t.a", " └─ExchangeReceiver 10000.00 mpp[tiflash] ", - " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.t.a, collate: binary]", + " └─ExchangeSender 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.t.a, collate: binary]", " └─TableFullScan 10000.00 mpp[tiflash] table:t keep order:false, stats:pseudo" ], "Warning": null @@ -7492,7 +7492,7 @@ "SQL": "select sum(a) from t -- sum shouldn't be rewritten", "Plan": [ "HashAgg 1.00 root funcs:sum(Column#12)->Column#10", - "└─TableReader 1.00 root data:ExchangeSender", + "└─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:sum(Column#15)->Column#12", " └─Projection 10000.00 mpp[tiflash] cast(test.t.a, decimal(10,0) BINARY)->Column#15", @@ -7513,35 +7513,35 @@ " └─HashAgg 1.00 root funcs:avg(distinct Column#89)->Column#11, funcs:min(Column#90)->Column#12, funcs:sum(distinct Column#91)->Column#13, funcs:max(Column#92)->Column#14", " └─Projection 7100.44 root cast(test.tbl_15.col_96, decimal(10,0) UNSIGNED BINARY)->Column#89, Column#15, cast(test.tbl_15.col_91, decimal(3,0) UNSIGNED BINARY)->Column#91, Column#16", " └─PartitionUnion 7100.44 root ", - " ├─TableReader 1775.11 root data:ExchangeSender", + " ├─TableReader 1775.11 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:min(Column#18)->Column#15, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91, funcs:max(Column#20)->Column#16, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91", " │ └─ExchangeReceiver 1775.11 mpp[tiflash] ", - " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", + " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:min(test.tbl_15.col_92)->Column#18, funcs:max(test.tbl_15.col_92)->Column#20", " │ └─Selection 2218.89 mpp[tiflash] gt(test.tbl_15.col_93, 7623.679908049186), ne(test.tbl_15.col_94, 2033-01-09 00:00:00.000000)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p0 keep order:false, stats:pseudo", - " ├─TableReader 1775.11 root data:ExchangeSender", + " ├─TableReader 1775.11 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:min(Column#30)->Column#15, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91, funcs:max(Column#32)->Column#16, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91", " │ └─ExchangeReceiver 1775.11 mpp[tiflash] ", - " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", + " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:min(test.tbl_15.col_92)->Column#30, funcs:max(test.tbl_15.col_92)->Column#32", " │ └─Selection 2218.89 mpp[tiflash] gt(test.tbl_15.col_93, 7623.679908049186), ne(test.tbl_15.col_94, 2033-01-09 00:00:00.000000)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p1 keep order:false, stats:pseudo", - " ├─TableReader 1775.11 root data:ExchangeSender", + " ├─TableReader 1775.11 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:min(Column#42)->Column#15, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91, funcs:max(Column#44)->Column#16, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91", " │ └─ExchangeReceiver 1775.11 mpp[tiflash] ", - " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", + " │ └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", " │ └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:min(test.tbl_15.col_92)->Column#42, funcs:max(test.tbl_15.col_92)->Column#44", " │ └─Selection 2218.89 mpp[tiflash] gt(test.tbl_15.col_93, 7623.679908049186), ne(test.tbl_15.col_94, 2033-01-09 00:00:00.000000)", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p2 keep order:false, stats:pseudo", - " └─TableReader 1775.11 root data:ExchangeSender", + " └─TableReader 1775.11 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:min(Column#54)->Column#15, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91, funcs:max(Column#56)->Column#16, funcs:firstrow(test.tbl_15.col_96)->test.tbl_15.col_96, funcs:firstrow(test.tbl_15.col_91)->test.tbl_15.col_91", " └─ExchangeReceiver 1775.11 mpp[tiflash] ", - " └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", + " └─ExchangeSender 1775.11 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.tbl_15.col_96, collate: binary], [name: test.tbl_15.col_91, collate: binary]", " └─HashAgg 1775.11 mpp[tiflash] group by:test.tbl_15.col_91, test.tbl_15.col_96, funcs:min(test.tbl_15.col_92)->Column#54, funcs:max(test.tbl_15.col_92)->Column#56", " └─Selection 2218.89 mpp[tiflash] gt(test.tbl_15.col_93, 7623.679908049186), ne(test.tbl_15.col_94, 2033-01-09 00:00:00.000000)", " └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p3 keep order:false, stats:pseudo" @@ -7554,22 +7554,22 @@ "HashAgg 1.00 root funcs:count(Column#12)->Column#11", "└─PartitionUnion 4.00 root ", " ├─HashAgg 1.00 root funcs:count(Column#13)->Column#12", - " │ └─TableReader 1.00 root data:ExchangeSender", + " │ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.tbl_15.col_91)->Column#13", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p0 keep order:false, stats:pseudo", " ├─HashAgg 1.00 root funcs:count(Column#14)->Column#12", - " │ └─TableReader 1.00 root data:ExchangeSender", + " │ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.tbl_15.col_91)->Column#14", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p1 keep order:false, stats:pseudo", " ├─HashAgg 1.00 root funcs:count(Column#15)->Column#12", - " │ └─TableReader 1.00 root data:ExchangeSender", + " │ └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " │ └─HashAgg 1.00 mpp[tiflash] funcs:count(test.tbl_15.col_91)->Column#15", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p2 keep order:false, stats:pseudo", " └─HashAgg 1.00 root funcs:count(Column#16)->Column#12", - " └─TableReader 1.00 root data:ExchangeSender", + " └─TableReader 1.00 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg 1.00 mpp[tiflash] funcs:count(test.tbl_15.col_91)->Column#16", " └─TableFullScan 10000.00 mpp[tiflash] table:tbl_15, partition:p3 keep order:false, stats:pseudo" @@ -7585,14 +7585,14 @@ " ├─StreamAgg 31.98 root group by:Column#22, funcs:count(Column#19)->Column#11, funcs:sum(Column#20)->Column#12, funcs:firstrow(Column#21)->test.tbl_16.col_100", " │ └─Projection 39.97 root test.tbl_16.col_100, cast(test.tbl_16.col_100, decimal(8,0) UNSIGNED BINARY)->Column#20, test.tbl_16.col_100, test.tbl_16.col_100", " │ └─Sort 39.97 root test.tbl_16.col_100", - " │ └─TableReader 39.97 root data:ExchangeSender", + " │ └─TableReader 39.97 root MppVersion: 1, data:ExchangeSender", " │ └─ExchangeSender 39.97 mpp[tiflash] ExchangeType: PassThrough", " │ └─Selection 39.97 mpp[tiflash] or(eq(test.tbl_16.col_100, 10672141), in(test.tbl_16.col_104, \"yfEG1t!*b\", \"C1*bqx_qyO\", \"vQ^yUpKHr&j#~\"))", " │ └─TableFullScan 10000.00 mpp[tiflash] table:tbl_16, partition:p0 keep order:false, stats:pseudo", " └─StreamAgg 31.98 root group by:Column#26, funcs:count(Column#23)->Column#11, funcs:sum(Column#24)->Column#12, funcs:firstrow(Column#25)->test.tbl_16.col_100", " └─Projection 39.97 root test.tbl_16.col_100, cast(test.tbl_16.col_100, decimal(8,0) UNSIGNED BINARY)->Column#24, test.tbl_16.col_100, test.tbl_16.col_100", " └─Sort 39.97 root test.tbl_16.col_100", - " └─TableReader 39.97 root data:ExchangeSender", + " └─TableReader 39.97 root MppVersion: 1, data:ExchangeSender", " └─ExchangeSender 39.97 mpp[tiflash] ExchangeType: PassThrough", " └─Selection 39.97 mpp[tiflash] or(eq(test.tbl_16.col_100, 10672141), in(test.tbl_16.col_104, \"yfEG1t!*b\", \"C1*bqx_qyO\", \"vQ^yUpKHr&j#~\"))", " └─TableFullScan 10000.00 mpp[tiflash] table:tbl_16, partition:p1 keep order:false, stats:pseudo" diff --git a/planner/core/testdata/window_push_down_suite_out.json b/planner/core/testdata/window_push_down_suite_out.json index 395c9e4ff61b6..f01f4e3cb2d3c 100644 --- a/planner/core/testdata/window_push_down_suite_out.json +++ b/planner/core/testdata/window_push_down_suite_out.json @@ -10,7 +10,7 @@ { "SQL": "explain select *, row_number() over () FROM employee -- 1. empty partition", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] row_number()->Column#6 over(rows between current row and current row)", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -22,7 +22,7 @@ { "SQL": "explain select *, row_number() over (order by salary) FROM employee -- 1.1 empty partition with sort", "Plan": [ - "TableReader_23 10000.00 root data:ExchangeSender_22", + "TableReader_23 10000.00 root MppVersion: 1, data:ExchangeSender_22", "└─ExchangeSender_22 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_21 10000.00 mpp[tiflash] row_number()->Column#6 over(order by test.employee.salary rows between current row and current row)", " └─Sort_13 10000.00 mpp[tiflash] test.employee.salary", @@ -35,12 +35,12 @@ { "SQL": "explain select *, row_number() over (partition by deptid) FROM employee -- 2. column partition key", "Plan": [ - "TableReader_24 10000.00 root data:ExchangeSender_23", + "TableReader_24 10000.00 root MppVersion: 1, data:ExchangeSender_23", "└─ExchangeSender_23 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_22 10000.00 mpp[tiflash] row_number()->Column#6 over(partition by test.employee.deptid rows between current row and current row), stream_count: 8", " └─Sort_13 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_10 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -48,13 +48,13 @@ { "SQL": "explain select *, row_number() over (partition by deptid+1) FROM employee -- 3. expression partition key", "Plan": [ - "TableReader_30 10000.00 root data:ExchangeSender_29", + "TableReader_30 10000.00 root MppVersion: 1, data:ExchangeSender_29", "└─ExchangeSender_29 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_7 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, Column#7, stream_count: 8", " └─Window_28 10000.00 mpp[tiflash] row_number()->Column#7 over(partition by Column#6 rows between current row and current row), stream_count: 8", " └─Sort_14 10000.00 mpp[tiflash] Column#6, stream_count: 8", " └─ExchangeReceiver_13 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_12 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#6, collate: binary], stream_count: 8", + " └─ExchangeSender_12 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#6, collate: binary], stream_count: 8", " └─Projection_10 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, plus(test.employee.deptid, 1)->Column#6", " └─TableFullScan_11 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], @@ -63,12 +63,12 @@ { "SQL": "explain select *, row_number() over (partition by deptid ORDER BY salary desc) FROM employee -- 3.1 with sort key", "Plan": [ - "TableReader_24 10000.00 root data:ExchangeSender_23", + "TableReader_24 10000.00 root MppVersion: 1, data:ExchangeSender_23", "└─ExchangeSender_23 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_22 10000.00 mpp[tiflash] row_number()->Column#6 over(partition by test.employee.deptid order by test.employee.salary desc rows between current row and current row), stream_count: 8", " └─Sort_13 10000.00 mpp[tiflash] test.employee.deptid, test.employee.salary:desc, stream_count: 8", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_10 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -76,12 +76,12 @@ { "SQL": "explain select *, rank() over w, dense_rank() over w from employee window w as (partition by deptid) -- 4. same kinds, multi function, same window", "Plan": [ - "TableReader_24 10000.00 root data:ExchangeSender_23", + "TableReader_24 10000.00 root MppVersion: 1, data:ExchangeSender_23", "└─ExchangeSender_23 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_22 10000.00 mpp[tiflash] rank()->Column#7, dense_rank()->Column#8 over(partition by test.employee.deptid), stream_count: 8", " └─Sort_13 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_10 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -89,14 +89,14 @@ { "SQL": "explain select *, row_number() over w, rank() over w from employee window w as (partition by deptid) -- 5. different kinds, multi functions, same window", "Plan": [ - "TableReader_36 10000.00 root data:ExchangeSender_35", + "TableReader_36 10000.00 root MppVersion: 1, data:ExchangeSender_35", "└─ExchangeSender_35 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_9 10000.00 mpp[tiflash] test.employee.empid, test.employee.deptid, test.employee.salary, Column#8, Column#7, stream_count: 8", " └─Window_34 10000.00 mpp[tiflash] row_number()->Column#8 over(partition by test.employee.deptid rows between current row and current row), stream_count: 8", " └─Window_12 10000.00 mpp[tiflash] rank()->Column#7 over(partition by test.employee.deptid), stream_count: 8", " └─Sort_17 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_16 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_15 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_15 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_14 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -104,7 +104,7 @@ { "SQL": "explain select *, rank() over () FROM (select *, row_number() over () a from employee) tmp -- 6. multi window from sub query", "Plan": [ - "TableReader_35 10000.00 root data:ExchangeSender_34", + "TableReader_35 10000.00 root MppVersion: 1, data:ExchangeSender_34", "└─ExchangeSender_34 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_33 10000.00 mpp[tiflash] rank()->Column#8 over()", " └─Window_14 10000.00 mpp[tiflash] row_number()->Column#6 over(rows between current row and current row)", @@ -117,12 +117,12 @@ { "SQL": "explain select *, rank() over (partition by deptid) FROM (select *, row_number() over () a from employee) tmp -- 6.1 multi window from sub query", "Plan": [ - "TableReader_36 10000.00 root data:ExchangeSender_35", + "TableReader_36 10000.00 root MppVersion: 1, data:ExchangeSender_35", "└─ExchangeSender_35 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_34 10000.00 mpp[tiflash] rank()->Column#8 over(partition by test.employee.deptid), stream_count: 8", " └─Sort_20 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_19 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_18 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_18 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─Window_14 10000.00 mpp[tiflash] row_number()->Column#6 over(rows between current row and current row)", " └─ExchangeReceiver_17 10000.00 mpp[tiflash] ", " └─ExchangeSender_16 10000.00 mpp[tiflash] ExchangeType: PassThrough", @@ -163,7 +163,7 @@ { "SQL": "explain select *, row_number() over () FROM employee -- 1. pure window functions", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] row_number()->Column#6 over(rows between current row and current row)", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -175,7 +175,7 @@ { "SQL": "explain select *, rank() over () FROM employee", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] rank()->Column#6 over()", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -187,7 +187,7 @@ { "SQL": "explain select *, dense_rank() over () FROM employee", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] dense_rank()->Column#6 over()", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -199,7 +199,7 @@ { "SQL": "explain select *, lead(empid) over () FROM employee", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] lead(test.employee.empid)->Column#6 over()", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -211,7 +211,7 @@ { "SQL": "explain select *, lag(empid) over () FROM employee", "Plan": [ - "TableReader_21 10000.00 root data:ExchangeSender_20", + "TableReader_21 10000.00 root MppVersion: 1, data:ExchangeSender_20", "└─ExchangeSender_20 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_19 10000.00 mpp[tiflash] lag(test.employee.empid)->Column#6 over()", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] ", @@ -283,12 +283,12 @@ { "SQL": "explain select *, row_number() over (partition by empid order by salary RANGE between 1 preceding and 1 following) FROM employee -- 3. range frame", "Plan": [ - "TableReader_24 10000.00 root data:ExchangeSender_23", + "TableReader_24 10000.00 root MppVersion: 1, data:ExchangeSender_23", "└─ExchangeSender_23 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_22 10000.00 mpp[tiflash] row_number()->Column#6 over(partition by test.employee.empid order by test.employee.salary rows between current row and current row), stream_count: 8", " └─Sort_13 10000.00 mpp[tiflash] test.employee.empid, test.employee.salary, stream_count: 8", " └─ExchangeReceiver_12 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.empid, collate: binary], stream_count: 8", + " └─ExchangeSender_11 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.empid, collate: binary], stream_count: 8", " └─TableFullScan_10 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": [ @@ -322,7 +322,7 @@ { "SQL": "explain select *, row_number() over () from (select count(distinct empid) from employee) t", "Plan": [ - "TableReader_61 1.00 root data:ExchangeSender_60", + "TableReader_61 1.00 root MppVersion: 1, data:ExchangeSender_60", "└─ExchangeSender_60 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_59 1.00 mpp[tiflash] row_number()->Column#7 over(rows between current row and current row)", " └─Projection_15 1.00 mpp[tiflash] Column#5", @@ -331,7 +331,7 @@ " └─ExchangeSender_19 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_16 1.00 mpp[tiflash] funcs:count(distinct test.employee.empid)->Column#8", " └─ExchangeReceiver_18 1.00 mpp[tiflash] ", - " └─ExchangeSender_17 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.empid, collate: binary]", + " └─ExchangeSender_17 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.empid, collate: binary]", " └─HashAgg_12 1.00 mpp[tiflash] group by:test.employee.empid, ", " └─TableFullScan_14 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], @@ -340,13 +340,13 @@ { "SQL": "explain select *, row_number() over () from (select count(empid) from employee group by deptid) t", "Plan": [ - "TableReader_84 8000.00 root data:ExchangeSender_83", + "TableReader_84 8000.00 root MppVersion: 1, data:ExchangeSender_83", "└─ExchangeSender_83 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_82 8000.00 mpp[tiflash] row_number()->Column#7 over(rows between current row and current row)", " └─Projection_21 8000.00 mpp[tiflash] Column#5", " └─HashAgg_22 8000.00 mpp[tiflash] group by:test.employee.deptid, funcs:sum(Column#8)->Column#5", " └─ExchangeReceiver_24 8000.00 mpp[tiflash] ", - " └─ExchangeSender_23 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender_23 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg_13 8000.00 mpp[tiflash] group by:test.employee.deptid, funcs:count(test.employee.empid)->Column#8", " └─TableFullScan_20 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], @@ -355,19 +355,19 @@ { "SQL": "explain select *, row_number() over (partition by a) from (select count(distinct empid) a from employee) t", "Plan": [ - "TableReader_49 1.00 root data:ExchangeSender_48", + "TableReader_49 1.00 root MppVersion: 1, data:ExchangeSender_48", "└─ExchangeSender_48 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_47 1.00 mpp[tiflash] row_number()->Column#7 over(partition by Column#5 rows between current row and current row), stream_count: 8", " └─Sort_22 1.00 mpp[tiflash] Column#5, stream_count: 8", " └─ExchangeReceiver_21 1.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_20 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#5, collate: binary], stream_count: 8", + " └─ExchangeSender_20 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#5, collate: binary], stream_count: 8", " └─Projection_14 1.00 mpp[tiflash] Column#5", " └─HashAgg_15 1.00 mpp[tiflash] funcs:sum(Column#8)->Column#5", " └─ExchangeReceiver_19 1.00 mpp[tiflash] ", " └─ExchangeSender_18 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_15 1.00 mpp[tiflash] funcs:count(distinct test.employee.empid)->Column#8", " └─ExchangeReceiver_17 1.00 mpp[tiflash] ", - " └─ExchangeSender_16 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.empid, collate: binary]", + " └─ExchangeSender_16 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.empid, collate: binary]", " └─HashAgg_12 1.00 mpp[tiflash] group by:test.employee.empid, ", " └─TableFullScan_13 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], @@ -376,14 +376,14 @@ { "SQL": "explain select *, row_number() over (partition by deptid) from (select count(empid), deptid from employee group by deptid) t", "Plan": [ - "TableReader_61 8000.00 root data:ExchangeSender_60", + "TableReader_61 8000.00 root MppVersion: 1, data:ExchangeSender_60", "└─ExchangeSender_60 8000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Window_59 8000.00 mpp[tiflash] row_number()->Column#7 over(partition by test.employee.deptid rows between current row and current row)", " └─Sort_24 8000.00 mpp[tiflash] test.employee.deptid", " └─Projection_20 8000.00 mpp[tiflash] Column#5, test.employee.deptid", " └─HashAgg_21 8000.00 mpp[tiflash] group by:test.employee.deptid, funcs:sum(Column#8)->Column#5, funcs:firstrow(test.employee.deptid)->test.employee.deptid", " └─ExchangeReceiver_23 8000.00 mpp[tiflash] ", - " └─ExchangeSender_22 8000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary]", + " └─ExchangeSender_22 8000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary]", " └─HashAgg_13 8000.00 mpp[tiflash] group by:test.employee.deptid, funcs:count(test.employee.empid)->Column#8", " └─TableFullScan_19 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], @@ -392,7 +392,7 @@ { "SQL": "explain select count(distinct empid) from (select *, row_number() over () from employee) t", "Plan": [ - "TableReader_35 1.00 root data:ExchangeSender_34", + "TableReader_35 1.00 root MppVersion: 1, data:ExchangeSender_34", "└─ExchangeSender_34 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_33 1.00 mpp[tiflash] Column#7", " └─HashAgg_32 1.00 mpp[tiflash] funcs:count(distinct test.employee.empid)->Column#7", @@ -406,7 +406,7 @@ { "SQL": "explain select count(distinct empid) from (select *, row_number() over (partition by deptid) from employee) t", "Plan": [ - "TableReader_49 1.00 root data:ExchangeSender_48", + "TableReader_49 1.00 root MppVersion: 1, data:ExchangeSender_48", "└─ExchangeSender_48 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_42 1.00 mpp[tiflash] Column#7", " └─HashAgg_43 1.00 mpp[tiflash] funcs:sum(Column#9)->Column#7", @@ -414,12 +414,12 @@ " └─ExchangeSender_46 1.00 mpp[tiflash] ExchangeType: PassThrough", " └─HashAgg_43 1.00 mpp[tiflash] funcs:count(distinct test.employee.empid)->Column#9", " └─ExchangeReceiver_45 1.00 mpp[tiflash] ", - " └─ExchangeSender_44 1.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.empid, collate: binary]", + " └─ExchangeSender_44 1.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.empid, collate: binary]", " └─HashAgg_41 1.00 mpp[tiflash] group by:test.employee.empid, , stream_count: 8", " └─Window_27 10000.00 mpp[tiflash] row_number()->Column#6 over(partition by test.employee.deptid rows between current row and current row), stream_count: 8", " └─Sort_18 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_17 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_16 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_16 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_15 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -427,7 +427,7 @@ { "SQL": "explain select count(empid) from (select *, row_number() over () a from employee) t group by a", "Plan": [ - "TableReader_52 10000.00 root data:ExchangeSender_51", + "TableReader_52 10000.00 root MppVersion: 1, data:ExchangeSender_51", "└─ExchangeSender_51 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_46 10000.00 mpp[tiflash] Column#7", " └─HashAgg_44 10000.00 mpp[tiflash] group by:Column#6, funcs:count(test.employee.empid)->Column#7", @@ -441,17 +441,17 @@ { "SQL": "explain select count(empid) from (select *, row_number() over (partition by deptid) a from employee) t group by a", "Plan": [ - "TableReader_54 10000.00 root data:ExchangeSender_53", + "TableReader_54 10000.00 root MppVersion: 1, data:ExchangeSender_53", "└─ExchangeSender_53 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_49 10000.00 mpp[tiflash] Column#7", " └─HashAgg_50 10000.00 mpp[tiflash] group by:Column#6, funcs:sum(Column#10)->Column#7", " └─ExchangeReceiver_52 10000.00 mpp[tiflash] ", - " └─ExchangeSender_51 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: Column#6, collate: binary]", + " └─ExchangeSender_51 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: Column#6, collate: binary]", " └─HashAgg_47 10000.00 mpp[tiflash] group by:Column#6, funcs:count(test.employee.empid)->Column#10, stream_count: 8", " └─Window_36 10000.00 mpp[tiflash] row_number()->Column#6 over(partition by test.employee.deptid rows between current row and current row), stream_count: 8", " └─Sort_21 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_20 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_19 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_19 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_18 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null @@ -459,7 +459,7 @@ { "SQL": "explain select row_number() over w2, row_number() over w1 from employee window w2 as (order by deptid), w1 as (partition by deptid);", "Plan": [ - "TableReader_37 10000.00 root data:ExchangeSender_36", + "TableReader_37 10000.00 root MppVersion: 1, data:ExchangeSender_36", "└─ExchangeSender_36 10000.00 mpp[tiflash] ExchangeType: PassThrough", " └─Projection_10 10000.00 mpp[tiflash] Column#8, Column#7", " └─Window_35 10000.00 mpp[tiflash] row_number()->Column#8 over(order by test.employee.deptid rows between current row and current row)", @@ -469,7 +469,7 @@ " └─Window_13 10000.00 mpp[tiflash] row_number()->Column#7 over(partition by test.employee.deptid rows between current row and current row), stream_count: 8", " └─Sort_17 10000.00 mpp[tiflash] test.employee.deptid, stream_count: 8", " └─ExchangeReceiver_16 10000.00 mpp[tiflash] stream_count: 8", - " └─ExchangeSender_15 10000.00 mpp[tiflash] ExchangeType: HashPartition, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", + " └─ExchangeSender_15 10000.00 mpp[tiflash] ExchangeType: HashPartition, Compression: FAST, Hash Cols: [name: test.employee.deptid, collate: binary], stream_count: 8", " └─TableFullScan_14 10000.00 mpp[tiflash] table:employee keep order:false, stats:pseudo" ], "Warn": null diff --git a/planner/optimize.go b/planner/optimize.go index 295d68b92f5a2..1ccd1c52f307b 100644 --- a/planner/optimize.go +++ b/planner/optimize.go @@ -251,6 +251,9 @@ func Optimize(ctx context.Context, sctx sessionctx.Context, node ast.Node, is in } else { sessVars.StmtCtx.AppendExtraNote(errors.Errorf("Using the bindSQL: %v", chosenBinding.BindSQL)) } + if len(tableHints) > 0 { + sessVars.StmtCtx.AppendWarning(errors.Errorf("The system ignores the hints in the current query and uses the hints specified in the bindSQL: %v", chosenBinding.BindSQL)) + } } // Restore the hint to avoid changing the stmt node. hint.BindHint(stmtNode, originHints) diff --git a/session/bootstrap.go b/session/bootstrap.go index d7e1643abbdeb..cb7d2f9e9a3df 100644 --- a/session/bootstrap.go +++ b/session/bootstrap.go @@ -24,7 +24,6 @@ import ( "fmt" "io/ioutil" osuser "os/user" - "runtime/debug" "strconv" "strings" "time" @@ -2515,8 +2514,7 @@ func mustExecute(s Session, sql string, args ...interface{}) { _, err := s.ExecuteInternal(ctx, sql, args...) defer cancel() if err != nil { - debug.PrintStack() - logutil.BgLogger().Fatal("mustExecute error", zap.Error(err)) + logutil.BgLogger().Fatal("mustExecute error", zap.Error(err), zap.Stack("stack")) } } diff --git a/sessionctx/variable/session.go b/sessionctx/variable/session.go index eb6eeadc72d79..6007b9ba3ad43 100644 --- a/sessionctx/variable/session.go +++ b/sessionctx/variable/session.go @@ -1034,6 +1034,10 @@ type SessionVars struct { // IsolationReadEngines is used to isolation read, tidb only read from the stores whose engine type is in the engines. IsolationReadEngines map[kv.StoreType]struct{} + mppVersion kv.MppVersion + + mppExchangeCompressionMode kv.ExchangeCompressionMode + PlannerSelectBlockAsName []ast.HintTable // LockWaitTimeout is the duration waiting for pessimistic lock in milliseconds @@ -1462,6 +1466,23 @@ func (s *SessionVars) IsMPPEnforced() bool { return s.allowMPPExecution && s.enforceMPPExecution } +// ChooseMppVersion indicates the mpp-version used to build mpp plan, if mpp-version is unspecified, use the latest version. +func (s *SessionVars) ChooseMppVersion() kv.MppVersion { + if s.mppVersion == kv.MppVersionUnspecified { + return kv.GetNewestMppVersion() + } + return s.mppVersion +} + +// ChooseMppExchangeCompressionMode indicates the data compression method in mpp exchange operator +func (s *SessionVars) ChooseMppExchangeCompressionMode() kv.ExchangeCompressionMode { + if s.mppExchangeCompressionMode == kv.ExchangeCompressionModeUnspecified { + // If unspecified, use recommended mode + return kv.RecommendedExchangeCompressionMode + } + return s.mppExchangeCompressionMode +} + // RaiseWarningWhenMPPEnforced will raise a warning when mpp mode is enforced and executing explain statement. // TODO: Confirm whether this function will be inlined and // omit the overhead of string construction when calling with false condition. @@ -1711,6 +1732,8 @@ func NewSessionVars(hctx HookContext) *SessionVars { EnableReuseCheck: DefTiDBEnableReusechunk, preUseChunkAlloc: DefTiDBUseAlloc, ChunkPool: ReuseChunkPool{Alloc: nil}, + mppExchangeCompressionMode: DefaultExchangeCompressionMode, + mppVersion: kv.MppVersionUnspecified, } vars.KVVars = tikvstore.NewVariables(&vars.Killed) vars.Concurrency = Concurrency{ diff --git a/sessionctx/variable/sysvar.go b/sessionctx/variable/sysvar.go index de0e5ffc90bd3..d9f8f9407b7fe 100644 --- a/sessionctx/variable/sysvar.go +++ b/sessionctx/variable/sysvar.go @@ -2223,6 +2223,54 @@ var defaultSysVars = []*SysVar{ return nil }, }, + {Scope: ScopeGlobal | ScopeSession, Name: MppExchangeCompressionMode, Type: TypeStr, Value: DefaultExchangeCompressionMode.Name(), + Validation: func(_ *SessionVars, normalizedValue string, originalValue string, _ ScopeFlag) (string, error) { + _, ok := kv.ToExchangeCompressionMode(normalizedValue) + if !ok { + var msg string + for m := kv.ExchangeCompressionModeNONE; m <= kv.ExchangeCompressionModeUnspecified; m += 1 { + if m == 0 { + msg = m.Name() + } else { + msg = fmt.Sprintf("%s, %s", msg, m.Name()) + } + } + err := fmt.Errorf("incorrect value: `%s`. %s options: %s", + originalValue, + MppExchangeCompressionMode, msg) + return normalizedValue, err + } + return normalizedValue, nil + }, + SetSession: func(s *SessionVars, val string) error { + s.mppExchangeCompressionMode, _ = kv.ToExchangeCompressionMode(val) + if s.ChooseMppVersion() == kv.MppVersionV0 && s.mppExchangeCompressionMode != kv.ExchangeCompressionModeUnspecified { + s.StmtCtx.AppendWarning(fmt.Errorf("mpp exchange compression won't work under current mpp version %d", kv.MppVersionV0)) + } + + return nil + }, + }, + {Scope: ScopeGlobal | ScopeSession, Name: MppVersion, Type: TypeStr, Value: kv.MppVersionUnspecifiedName, + Validation: func(_ *SessionVars, normalizedValue string, originalValue string, _ ScopeFlag) (string, error) { + _, ok := kv.ToMppVersion(normalizedValue) + if ok { + return normalizedValue, nil + } + errMsg := fmt.Sprintf("incorrect value: %s. %s options: %d (unspecified)", + originalValue, MppVersion, kv.MppVersionUnspecified) + for i := kv.MppVersionV0; i <= kv.GetNewestMppVersion(); i += 1 { + errMsg = fmt.Sprintf("%s, %d", errMsg, i) + } + + return normalizedValue, errors.New(errMsg) + }, + SetSession: func(s *SessionVars, val string) error { + version, _ := kv.ToMppVersion(val) + s.mppVersion = version + return nil + }, + }, { Scope: ScopeGlobal, Name: TiDBTTLJobScheduleWindowStartTime, Value: DefTiDBTTLJobScheduleWindowStartTime, Type: TypeTime, SetGlobal: func(ctx context.Context, vars *SessionVars, s string) error { startTime, err := time.ParseInLocation(FullDayTimeFormat, s, time.UTC) diff --git a/sessionctx/variable/tidb_vars.go b/sessionctx/variable/tidb_vars.go index c86795937d544..2149e2387f236 100644 --- a/sessionctx/variable/tidb_vars.go +++ b/sessionctx/variable/tidb_vars.go @@ -21,6 +21,7 @@ import ( "time" "github.com/pingcap/tidb/config" + "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/parser/mysql" "github.com/pingcap/tidb/sessionctx/variable/featuretag/distributereorg" "github.com/pingcap/tidb/util/memory" @@ -793,6 +794,12 @@ const ( // TiDBStoreBatchSize indicates the batch size of coprocessor in the same store. TiDBStoreBatchSize = "tidb_store_batch_size" + // MppExchangeCompressionMode indicates the data compression method in mpp exchange operator + MppExchangeCompressionMode = "mpp_exchange_compression_mode" + + // MppVersion indicates the mpp-version used to build mpp plan + MppVersion = "mpp_version" + // TiDBPessimisticTransactionAggressiveLocking controls whether aggressive locking for pessimistic transaction // is enabled. TiDBPessimisticTransactionAggressiveLocking = "tidb_pessimistic_txn_aggressive_locking" @@ -1168,6 +1175,7 @@ const ( DefTiDBTTLJobScheduleWindowEndTime = "23:59 +0000" DefTiDBTTLScanWorkerCount = 4 DefTiDBTTLDeleteWorkerCount = 4 + DefaultExchangeCompressionMode = kv.ExchangeCompressionModeUnspecified DefTiDBEnableResourceControl = false DefTiDBPessimisticTransactionAggressiveLocking = false DefTiDBEnablePlanCacheForParamLimit = true diff --git a/store/copr/mpp.go b/store/copr/mpp.go index 9af0bb919593c..49b44922aa2ce 100644 --- a/store/copr/mpp.go +++ b/store/copr/mpp.go @@ -146,6 +146,8 @@ type mppIterator struct { startTs uint64 mppQueryID kv.MPPQueryID + mppVersion kv.MppVersion + respChan chan *mppResponse cancelFunc context.CancelFunc @@ -222,7 +224,9 @@ func (m *mppIterator) handleDispatchReq(ctx context.Context, bo *Backoffer, req // meta for current task. taskMeta := &mpp.TaskMeta{StartTs: req.StartTs, QueryTs: req.MppQueryID.QueryTs, LocalQueryId: req.MppQueryID.LocalQueryID, TaskId: req.ID, ServerId: req.MppQueryID.ServerID, - Address: req.Meta.GetAddress()} + Address: req.Meta.GetAddress(), + MppVersion: m.mppVersion.ToInt64(), + } mppReq := &mpp.DispatchTaskRequest{ Meta: taskMeta, @@ -257,7 +261,7 @@ func (m *mppIterator) handleDispatchReq(ctx context.Context, bo *Backoffer, req // TODO: If we want to retry, we must redo the plan fragment cutting and task scheduling. // That's a hard job but we can try it in the future. if sender.GetRPCError() != nil { - logutil.BgLogger().Warn("mpp dispatch meet io error", zap.String("error", sender.GetRPCError().Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Warn("mpp dispatch meet io error", zap.String("error", sender.GetRPCError().Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) // if needTriggerFallback is true, we return timeout to trigger tikv's fallback if m.needTriggerFallback { err = derr.ErrTiFlashServerTimeout @@ -277,13 +281,13 @@ func (m *mppIterator) handleDispatchReq(ctx context.Context, bo *Backoffer, req } if retry { - logutil.BgLogger().Warn("mpp dispatch meet error and retrying", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Warn("mpp dispatch meet error and retrying", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) m.handleDispatchReq(ctx, bo, req) return } if err != nil { - logutil.BgLogger().Error("mpp dispatch meet error", zap.String("error", err.Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Error("mpp dispatch meet error", zap.String("error", err.Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) // if needTriggerFallback is true, we return timeout to trigger tikv's fallback if m.needTriggerFallback { err = derr.ErrTiFlashServerTimeout @@ -295,7 +299,7 @@ func (m *mppIterator) handleDispatchReq(ctx context.Context, bo *Backoffer, req realResp := rpcResp.Resp.(*mpp.DispatchTaskResponse) if realResp.Error != nil { - logutil.BgLogger().Error("mpp dispatch response meet error", zap.String("error", realResp.Error.Msg), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Error("mpp dispatch response meet error", zap.String("error", realResp.Error.Msg), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("task-mpp-version", taskMeta.MppVersion), zap.Int64("error-mpp-version", realResp.Error.GetMppVersion())) m.sendError(errors.New(realResp.Error.Msg)) return } @@ -329,7 +333,7 @@ func (m *mppIterator) cancelMppTasks() { m.mu.Lock() defer m.mu.Unlock() killReq := &mpp.CancelTaskRequest{ - Meta: &mpp.TaskMeta{StartTs: m.startTs, QueryTs: m.mppQueryID.QueryTs, LocalQueryId: m.mppQueryID.LocalQueryID, ServerId: m.mppQueryID.ServerID}, + Meta: &mpp.TaskMeta{StartTs: m.startTs, QueryTs: m.mppQueryID.QueryTs, LocalQueryId: m.mppQueryID.LocalQueryID, ServerId: m.mppQueryID.ServerID, MppVersion: m.mppVersion.ToInt64()}, } wrappedReq := tikvrpc.NewRequest(tikvrpc.CmdMPPCancel, killReq, kvrpcpb.Context{}) @@ -352,9 +356,9 @@ func (m *mppIterator) cancelMppTasks() { storeAddr := addr wg.Run(func() { _, err := m.store.GetTiKVClient().SendRequest(context.Background(), storeAddr, wrappedReq, tikv.ReadTimeoutShort) - logutil.BgLogger().Debug("cancel task", zap.Uint64("query id ", m.startTs), zap.String("on addr", storeAddr)) + logutil.BgLogger().Debug("cancel task", zap.Uint64("query id ", m.startTs), zap.String("on addr", storeAddr), zap.Int64("mpp-version", m.mppVersion.ToInt64())) if err != nil { - logutil.BgLogger().Error("cancel task error", zap.Error(err), zap.Uint64("query id", m.startTs), zap.String("on addr", storeAddr)) + logutil.BgLogger().Error("cancel task error", zap.Error(err), zap.Uint64("query id", m.startTs), zap.String("on addr", storeAddr), zap.Int64("mpp-version", m.mppVersion.ToInt64())) } }) } @@ -369,6 +373,7 @@ func (m *mppIterator) establishMPPConns(bo *Backoffer, req *kv.MPPDispatchReques QueryTs: m.mppQueryID.QueryTs, LocalQueryId: m.mppQueryID.LocalQueryID, ServerId: m.mppQueryID.ServerID, + MppVersion: m.mppVersion.ToInt64(), TaskId: -1, }, } @@ -383,7 +388,7 @@ func (m *mppIterator) establishMPPConns(bo *Backoffer, req *kv.MPPDispatchReques rpcResp, err := m.store.GetTiKVClient().SendRequest(bo.GetCtx(), req.Meta.GetAddress(), wrappedReq, readTimeoutUltraLong) if err != nil { - logutil.BgLogger().Warn("establish mpp connection meet error and cannot retry", zap.String("error", err.Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Warn("establish mpp connection meet error and cannot retry", zap.String("error", err.Error()), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) // if needTriggerFallback is true, we return timeout to trigger tikv's fallback if m.needTriggerFallback { m.sendError(derr.ErrTiFlashServerTimeout) @@ -416,9 +421,9 @@ func (m *mppIterator) establishMPPConns(bo *Backoffer, req *kv.MPPDispatchReques if err1 := bo.Backoff(tikv.BoTiKVRPC(), errors.Errorf("recv stream response error: %v", err)); err1 != nil { if errors.Cause(err) == context.Canceled { - logutil.BgLogger().Info("stream recv timeout", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Info("stream recv timeout", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) } else { - logutil.BgLogger().Info("stream unknown error", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId)) + logutil.BgLogger().Info("stream unknown error", zap.Error(err), zap.Uint64("timestamp", taskMeta.StartTs), zap.Int64("task", taskMeta.TaskId), zap.Int64("mpp-version", taskMeta.MppVersion)) } } // if needTriggerFallback is true, we return timeout to trigger tikv's fallback @@ -448,6 +453,7 @@ func (m *mppIterator) handleMPPStreamResponse(bo *Backoffer, response *mpp.MPPDa logutil.BgLogger().Warn("other error", zap.Uint64("txnStartTS", req.StartTs), zap.String("storeAddr", req.Meta.GetAddress()), + zap.Int64("mpp-version", m.mppVersion.ToInt64()), zap.Error(err)) return err } @@ -518,7 +524,7 @@ func (m *mppIterator) Next(ctx context.Context) (kv.ResultSubset, error) { } // DispatchMPPTasks dispatches all the mpp task and waits for the responses. -func (c *MPPClient) DispatchMPPTasks(ctx context.Context, variables interface{}, dispatchReqs []*kv.MPPDispatchRequest, needTriggerFallback bool, startTs uint64, mppQueryID kv.MPPQueryID) kv.Response { +func (c *MPPClient) DispatchMPPTasks(ctx context.Context, variables interface{}, dispatchReqs []*kv.MPPDispatchRequest, needTriggerFallback bool, startTs uint64, mppQueryID kv.MPPQueryID, mppVersion kv.MppVersion) kv.Response { vars := variables.(*tikv.Variables) ctxChild, cancelFunc := context.WithCancel(ctx) iter := &mppIterator{ @@ -530,6 +536,7 @@ func (c *MPPClient) DispatchMPPTasks(ctx context.Context, variables interface{}, respChan: make(chan *mppResponse), startTs: startTs, mppQueryID: mppQueryID, + mppVersion: mppVersion, vars: vars, needTriggerFallback: needTriggerFallback, enableCollectExecutionInfo: config.GetGlobalConfig().Instance.EnableCollectExecutionInfo.Load(), diff --git a/store/mockstore/unistore/rpc.go b/store/mockstore/unistore/rpc.go index b0e88e533582d..15fe6828ddabf 100644 --- a/store/mockstore/unistore/rpc.go +++ b/store/mockstore/unistore/rpc.go @@ -265,6 +265,11 @@ func (c *RPCClient) SendRequest(ctx context.Context, addr string, req *tikvrpc.R failpoint.Return(nil, errors.New("rpc error")) } }) + failpoint.Inject("MppVersionError", func(val failpoint.Value) { + if v := int64(val.(int)); v > req.EstablishMPPConn().GetReceiverMeta().GetMppVersion() || v > req.EstablishMPPConn().GetSenderMeta().GetMppVersion() { + failpoint.Return(nil, context.Canceled) + } + }) resp.Resp, err = c.handleEstablishMPPConnection(ctx, req.EstablishMPPConn(), timeout, storeID) case tikvrpc.CmdMPPTask: failpoint.Inject("mppDispatchTimeout", func(val failpoint.Value) { @@ -272,6 +277,11 @@ func (c *RPCClient) SendRequest(ctx context.Context, addr string, req *tikvrpc.R failpoint.Return(nil, errors.New("rpc error")) } }) + failpoint.Inject("MppVersionError", func(val failpoint.Value) { + if v := int64(val.(int)); v > req.DispatchMPPTask().GetMeta().GetMppVersion() { + failpoint.Return(nil, context.Canceled) + } + }) resp.Resp, err = c.handleDispatchMPPTask(ctx, req.DispatchMPPTask(), storeID) case tikvrpc.CmdMPPCancel: case tikvrpc.CmdMvccGetByKey: