Hello Quanlong Huang, Aman Sinha, Joe McDonnell, Michael Smith, Impala Public
Jenkins,
I'd like you to reexamine a change. Please visit
https://gerrit.cloudera.org/25372
to look at the new patch set (#2).
Change subject: IMPALA-15753: Calcite planner: avoid LIKE wildcard
simplification
......................................................................
IMPALA-15753: Calcite planner: avoid LIKE wildcard simplification
Calcite collapses adjacent LIKE percent signs, so '%%' becomes '%'.
That rewrite changes Impala's result when a backslash escape
precedes the wildcards. The pattern 'a\\%%' is not the same as
'a\\%': the extra percent sign stays a wildcard.
Skip LIKE simplification when the pattern contains a percent sign.
A pattern made only of percent signs still simplifies to "x = x".
Collapsing three percent signs to two is possible, but that edge
case is not worth the extra code.
Testing: Added LIKE expressions that previously failed to
calcite.test.
Change-Id: I93b3a7ecad92c373e79e6a5c74e25841400a56e3
---
M
java/calcite-planner/src/main/java/org/apache/impala/calcite/operators/ImpalaRexSimplify.java
M testdata/workloads/functional-query/queries/QueryTest/calcite.test
2 files changed, 65 insertions(+), 0 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/72/25372/2
--
To view, visit https://gerrit.cloudera.org/25372
To unsubscribe, visit https://gerrit.cloudera.org/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I93b3a7ecad92c373e79e6a5c74e25841400a56e3
Gerrit-Change-Number: 25372
Gerrit-PatchSet: 2
Gerrit-Owner: Steve Carlin <[email protected]>
Gerrit-Reviewer: Aman Sinha <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Michael Smith <[email protected]>
Gerrit-Reviewer: Quanlong Huang <[email protected]>