Stamatis Zampetakis created CALCITE-6608:
--------------------------------------------
Summary: RexBuilder#makeIn should create EQUALS instead of SEARCH
for single point values
Key: CALCITE-6608
URL: https://issues.apache.org/jira/browse/CALCITE-6608
Project: Calcite
Issue Type: Improvement
Components: core
Reporter: Stamatis Zampetakis
Assignee: Stamatis Zampetakis
{code:java}
RexBuilder.makeIn(inputRef(0), ImmutableList.of(literal(100)))
{code}
Current behavior:
{noformat}
SEARCH($0, Sarg[100])
{noformat}
Proposed behavior:
{noformat}
=($0, 100)
{noformat}
The EQUALS operator is simpler than the SEARCH operator and it is handled
better by other components. Although, the SEARCH to EQUALS transformation is
already something that is done during simplification not every piece of code
calls the simplifier.
This basic simplification could also be done directly inside the makeIn method
when the caller passes a single point value.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)