Skip to content

Commit 8131014

Browse files
committed
test: update prefix range expectations
1 parent 137e6e4 commit 8131014

4 files changed

Lines changed: 7 additions & 7 deletions

File tree

pkg/planner/core/casetest/indexmerge/testdata/index_merge_suite_out.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
"SQL": "select /*+ use_index_merge(t6, primary, is3, is4) */ * from t6 where s1 = 'Abc' and s2 > 'zzz' and s3 = 'A啊a' and s4 not like 'Cd_'",
144144
"Plan": [
145145
"IndexMerge root type: intersection",
146-
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:PRIMARY(s1, s2) range:(\"Abc\" \"zzz\",\"Abc\" +inf], keep order:false, stats:pseudo",
146+
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:PRIMARY(s1, s2) range:[\"Abc\" \"zzz\",\"Abc\" +inf], keep order:false, stats:pseudo",
147147
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:is3(s3) range:[\"\\x0e3\\xfb@\\xd5J\\x0e3\",\"\\x0e3\\xfb@\\xd5J\\x0e3\"], keep order:false, stats:pseudo",
148148
"└─Selection(Probe) cop[tikv] gt(test.t6.s2, \"zzz\"), not(like(test.t6.s4, \"Cd_\", 92))",
149149
" └─TableRowIDScan cop[tikv] table:t6 keep order:false, stats:pseudo"
@@ -176,7 +176,7 @@
176176
"└─IndexMerge root type: intersection",
177177
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:PRIMARY(s1) range:[\"UJ\\x00A\",\"UJ\\x00B\"), keep order:false, stats:pseudo",
178178
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is2(s2) range:(\"abc\",+inf], keep order:false, stats:pseudo",
179-
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is3(s3) range:(\"cba\",+inf], keep order:false, stats:pseudo",
179+
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is3(s3) range:[\"cba\",+inf], keep order:false, stats:pseudo",
180180
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is4(s4) range:[\"aA\",\"aA\"], [\"??\",\"??\"], keep order:false, stats:pseudo",
181181
" └─Selection(Probe) cop[tikv] gt(test.t8.s3, \"cba\"), like(test.t8.s1, \"啊A%\", 92)",
182182
" └─TableRowIDScan cop[tikv] table:t8 keep order:false, stats:pseudo"

pkg/planner/core/casetest/indexmerge/testdata/index_merge_suite_xut.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
"SQL": "select /*+ use_index_merge(t6, primary, is3, is4) */ * from t6 where s1 = 'Abc' and s2 > 'zzz' and s3 = 'A啊a' and s4 not like 'Cd_'",
144144
"Plan": [
145145
"IndexMerge root type: intersection",
146-
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:PRIMARY(s1, s2) range:(\"Abc\" \"zzz\",\"Abc\" +inf], keep order:false, stats:pseudo",
146+
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:PRIMARY(s1, s2) range:[\"Abc\" \"zzz\",\"Abc\" +inf], keep order:false, stats:pseudo",
147147
"├─IndexRangeScan(Build) cop[tikv] table:t6, index:is3(s3) range:[\"\\x0e3\\xfb@\\xd5J\\x0e3\",\"\\x0e3\\xfb@\\xd5J\\x0e3\"], keep order:false, stats:pseudo",
148148
"└─Selection(Probe) cop[tikv] gt(test.t6.s2, \"zzz\"), not(like(test.t6.s4, \"Cd_\", 92))",
149149
" └─TableRowIDScan cop[tikv] table:t6 keep order:false, stats:pseudo"
@@ -176,7 +176,7 @@
176176
"└─IndexMerge root type: intersection",
177177
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:PRIMARY(s1) range:[\"UJ\\x00A\",\"UJ\\x00B\"), keep order:false, stats:pseudo",
178178
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is2(s2) range:(\"abc\",+inf], keep order:false, stats:pseudo",
179-
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is3(s3) range:(\"cba\",+inf], keep order:false, stats:pseudo",
179+
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is3(s3) range:[\"cba\",+inf], keep order:false, stats:pseudo",
180180
" ├─IndexRangeScan(Build) cop[tikv] table:t8, index:is4(s4) range:[\"aA\",\"aA\"], [\"??\",\"??\"], keep order:false, stats:pseudo",
181181
" └─Selection(Probe) cop[tikv] gt(test.t8.s3, \"cba\"), like(test.t8.s1, \"啊A%\", 92)",
182182
" └─TableRowIDScan cop[tikv] table:t8 keep order:false, stats:pseudo"

tests/integrationtest/r/imdbload.result

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ TableReader 106389.00 root data:Selection
327327
explain format = 'brief' select * from keyword where ((phonetic_code = 'R1652') and (keyword > 'ecg-monitor' and keyword < 'killers'));
328328
id estRows task access object operator info
329329
IndexLookUp 901.00 root
330-
├─IndexRangeScan(Build) 901.00 cop[tikv] table:keyword, index:itest(phonetic_code, keyword) range:("R1652" "ecg-monitor","R1652" "killers"), keep order:false
330+
├─IndexRangeScan(Build) 901.00 cop[tikv] table:keyword, index:itest(phonetic_code, keyword) range:["R1652" "ecg-monitor","R1652" "killers"), keep order:false
331331
└─Selection(Probe) 901.00 cop[tikv] gt(imdbload.keyword.keyword, "ecg-monitor"), lt(imdbload.keyword.keyword, "killers")
332332
└─TableRowIDScan 901.00 cop[tikv] table:keyword keep order:false
333333
explain format = 'brief' select * from cast_info where (nr_order is null) and (person_role_id = 2) and (note >= '(key set pa: Florida');

tests/integrationtest/r/planner/core/range_scan_for_like.result

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ id task access object operator info
700700
Projection root planner__core__range_scan_for_like.t.a, planner__core__range_scan_for_like.t.b
701701
└─Sort root planner__core__range_scan_for_like.t.a, planner__core__range_scan_for_like.t._tidb_rowid
702702
└─IndexLookUp root
703-
├─IndexRangeScan(Build) cop[tikv] table:t, index:ia(a, b) range:("\x00A\x00A",+inf], keep order:false, stats:pseudo
703+
├─IndexRangeScan(Build) cop[tikv] table:t, index:ia(a, b) range:["\x00A\x00A",+inf], keep order:false, stats:pseudo
704704
└─Selection(Probe) cop[tikv] gt(planner__core__range_scan_for_like.t.a, "aa")
705705
└─TableRowIDScan cop[tikv] table:t keep order:false, stats:pseudo
706706
select * from t use index (ia) where a > 'aa' order by a,_tidb_rowid;
@@ -1000,7 +1000,7 @@ id task access object operator info
10001000
Projection root planner__core__range_scan_for_like.t.a, planner__core__range_scan_for_like.t.b
10011001
└─Sort root planner__core__range_scan_for_like.t.a, planner__core__range_scan_for_like.t._tidb_rowid
10021002
└─IndexLookUp root
1003-
├─IndexRangeScan(Build) cop[tikv] table:t, index:ia(a, b) range:(NULL,"\x00D\x00D"), ("\x00D\x00D",+inf], keep order:false, stats:pseudo
1003+
├─IndexFullScan(Build) cop[tikv] table:t, index:ia(a, b) keep order:false, stats:pseudo
10041004
└─Selection(Probe) cop[tikv] not(in(planner__core__range_scan_for_like.t.a, "aabc", "dd"))
10051005
└─TableRowIDScan cop[tikv] table:t keep order:false, stats:pseudo
10061006
select * from t use index (ia) where a not in ('aabc','dd') order by a,_tidb_rowid;

0 commit comments

Comments
 (0)