【 TiDB 使用环境】生产环境
【 TiDB 版本】V6.5.0
同一个SQL在6.1.2版本是正常,在6.5.0版本查询报错误ERROR 1105 (HY000): runtime error: index out of range [1] with length 0
,错误的堆栈日志为:
[2023/01/04 09:31:37.291 +08:00] [ERROR] [index_lookup_join.go:484] ["innerWorker panicked"] [conn=5156021239990909561] [recover="runtime error: index out of range [1] with length 0"] [stack="github.com/pingcap/tidb/executor.(*innerWorker).run.func1
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/index_lookup_join.go:484
runtime.gopanic
/usr/local/go/src/runtime/panic.go:884
runtime.goPanicIndex
/usr/local/go/src/runtime/panic.go:113
github.com/pingcap/tidb/util/chunk.setMutRowBytes
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/util/chunk/mutrow.go:335
github.com/pingcap/tidb/util/chunk.MutRow.SetDatum
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/util/chunk/mutrow.go:305
github.com/pingcap/tidb/util/chunk.MutRow.SetDatums
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/util/chunk/mutrow.go:288
github.com/pingcap/tidb/table/tables.(*partitionedTable).locateRangeColumnPartition.func1
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/table/tables/partition.go:1010
sort.Search
/usr/local/go/src/sort/search.go:65
github.com/pingcap/tidb/table/tables.(*partitionedTable).locateRangeColumnPartition
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/table/tables/partition.go:1009
github.com/pingcap/tidb/table/tables.(*partitionedTable).locatePartition
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/table/tables/partition.go:991
github.com/pingcap/tidb/table/tables.(*partitionedTable).GetPartitionByRow
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/table/tables/partition.go:1159
github.com/pingcap/tidb/executor.(*dataReaderBuilder).buildTableReaderForIndexJoin
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/builder.go:4169
github.com/pingcap/tidb/executor.(*dataReaderBuilder).buildExecutorForIndexJoinInternal
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/builder.go:4064
github.com/pingcap/tidb/executor.(*dataReaderBuilder).buildExecutorForIndexJoin
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/builder.go:4057
github.com/pingcap/tidb/executor.(*innerWorker).fetchInnerResults
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/index_lookup_join.go:690
github.com/pingcap/tidb/executor.(*innerWorker).handleTask
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/index_lookup_join.go:528
github.com/pingcap/tidb/executor.(*innerWorker).run
/home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tidb/executor/index_lookup_join.go:502"]
PS: 感觉是解决另外一个BUG时引入的新BUG。。。