[
https://issues.apache.org/jira/browse/CALCITE-6608?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Stamatis Zampetakis resolved CALCITE-6608.
------------------------------------------
Fix Version/s: 1.39.0
Resolution: Fixed
Fixed in
[b0ecd066df37bbc2398973165ddffe96135b4303|https://github.com/apache/calcite/commit/b0ecd066df37bbc2398973165ddffe96135b4303].
Thanks for the reviews [~cancai], [~rubenql], [~nobigo], [~julianhyde]!
> 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
> Priority: Minor
> Labels: pull-request-available
> Fix For: 1.39.0
>
>
> {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)