[
https://issues.apache.org/jira/browse/CALCITE-7196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Mihai Budiu resolved CALCITE-7196.
----------------------------------
Fix Version/s: 1.42.0
Resolution: Fixed
Fixed in
[https://github.com/apache/calcite/commit/2a6ce48a97465f37f7fdf97b8d6fab56919f2064]
Thank you for the reviews [~jensen] and [~dmsysolyatin]
> Create an optimization pass which can convert some cases of Correlate +
> Unnest to Unnest
> ----------------------------------------------------------------------------------------
>
> Key: CALCITE-7196
> URL: https://issues.apache.org/jira/browse/CALCITE-7196
> Project: Calcite
> Issue Type: New Feature
> Components: core
> Affects Versions: 1.40.0
> Reporter: Mihai Budiu
> Assignee: Mihai Budiu
> Priority: Minor
> Labels: pull-request-available
> Fix For: 1.42.0
>
>
> Today UNNEST is always compiled into a Correlate + Unnest.
> Some query plans of this shape can be simplified however:
> {code}
> Project
> Correlate
> LeftInput
> Uncollect
> Project(correlatedVariable) // only one field here
> Values
> {code}
> If the Project only preserves fields from the right-side of the Correlate,
> such plans can be rewritten as
> {code}
> Project
> Uncollect
> LeftInput
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)