[
https://issues.apache.org/jira/browse/CALCITE-5663?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Marieke Gueye updated CALCITE-5663:
-----------------------------------
Description:
In RelOptFixture, we currently change the traitsets to enforce
EnumerableConvention.INSTANCE, however, in this instance we forget to port the
collation in the traitset.
{code:java}
if (planner instanceof VolcanoPlanner)
{ r2 = planner.changeTraits(relBefore,
relBefore.getTraitSet().replace(EnumerableConvention.INSTANCE)); }
else
{ r2 = relBefore; }
{code}
The problem goes even deeper, as of now, there is no way to get access to the
collation as it lives in the relRoot, and we currently only access the relNode
through the relSupplier
The consequence of this can be pretty dire as it may mean that some rules might
be incorrectly tested.
was:
In RelOptFixture, we currently change the traitsets to enforce
EnumerableConvention.INSTANCE, however, in this instance we forget to port the
collation in the traitset.
```
if (planner instanceof VolcanoPlanner) {
r2 =
planner.changeTraits(relBefore,
relBefore.getTraitSet().replace(EnumerableConvention.INSTANCE));
} else {
r2 = relBefore;
}
```
The problem goes even deeper, as of now, there is no way to get access to the
collation as it lives in the relRoot, and we currently only access the relNode
through the `relSupplier`
The consequence of this can be pretty dire as it may mean that some rules might
be incorrectly tested.
> [TestKit] RelOptFixture does not enforce the collation
> ------------------------------------------------------
>
> Key: CALCITE-5663
> URL: https://issues.apache.org/jira/browse/CALCITE-5663
> Project: Calcite
> Issue Type: Bug
> Reporter: Marieke Gueye
> Priority: Minor
>
> In RelOptFixture, we currently change the traitsets to enforce
> EnumerableConvention.INSTANCE, however, in this instance we forget to port
> the collation in the traitset.
> {code:java}
> if (planner instanceof VolcanoPlanner)
> { r2 = planner.changeTraits(relBefore,
> relBefore.getTraitSet().replace(EnumerableConvention.INSTANCE)); }
> else
> { r2 = relBefore; }
>
> {code}
> The problem goes even deeper, as of now, there is no way to get access to the
> collation as it lives in the relRoot, and we currently only access the
> relNode through the relSupplier
>
> The consequence of this can be pretty dire as it may mean that some rules
> might be incorrectly tested.
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)