planner: fix uncorrect behavior of index join#11724
Conversation
| resultStr: "[[\"a\",\"a\"]]", | ||
| length: 1, | ||
| }, | ||
| // This test case cannot be simplified to [1, 3] otherwise the index join will executes wrongly. |
There was a problem hiding this comment.
Use this test to assert that there won't be range merging in this case.
There was a problem hiding this comment.
Why can't merge to [1,3]? Because of the prefix index?
|
@winoros ci failed. Σ(° △ °|||)︴ |
|
@lzmhhh123 Yeah, i'm solving another one. Will fix it later. |
73f36c2 to
38a329e
Compare
|
@lzmhhh123 fixed |
|
/run-all-tests |
Codecov Report
@@ Coverage Diff @@
## master #11724 +/- ##
================================================
- Coverage 81.5578% 81.4561% -0.1017%
================================================
Files 434 433 -1
Lines 93937 93147 -790
================================================
- Hits 76613 75874 -739
+ Misses 11876 11842 -34
+ Partials 5448 5431 -17 |
|
/run-sqllogic-test |
| indexInfo := path.index | ||
| err := helper.analyzeLookUpFilters(indexInfo, ds, innerJoinKeys) | ||
| emptyRange, err := helper.analyzeLookUpFilters(indexInfo, ds, innerJoinKeys) | ||
| if emptyRange { |
There was a problem hiding this comment.
Otherwise we may need to return a HashJoin{Reader, Dual}. Which i think is a little strange.
There was a problem hiding this comment.
Can you add a unit test to cover it?
|
/run-all-tests |
|
@winoros merge failed. |
|
/run-all-tests |
|
/run-auto-merge |
|
/run-all-tests |
|
cherry pick to release-3.0 failed |
What problem does this PR solve?
close #11544 and close #11390
What is changed and how it works?
Use
BuildColumnRangeto build template range for index join.To fix two cases:
Check List
Tests
Side effects
Related changes