zstan commented on a change in pull request #8472:
URL: https://github.com/apache/ignite/pull/8472#discussion_r527485038
##########
File path:
modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/rule/FilterConverterRule.java
##########
@@ -37,14 +42,25 @@
/** */
public FilterConverterRule() {
- super(LogicalFilter.class);
+ super(LogicalFilter.class, "FilterConverterRule");
}
/** {@inheritDoc} */
@Override protected PhysicalNode convert(RelOptPlanner planner,
RelMetadataQuery mq, LogicalFilter rel) {
RelOptCluster cluster = rel.getCluster();
- RelTraitSet traits = cluster.traitSetOf(IgniteConvention.INSTANCE);
- RelNode input = convert(rel.getInput(), traits);
+ RelTraitSet traits =
rel.getTraitSet().replace(IgniteConvention.INSTANCE);
+ RelTraitSet inTraits =
rel.getTraitSet().replace(IgniteConvention.INSTANCE);
+ RelNode input = rel.getInput();
+
+ Set<CorrelationId> corrIds =
RexUtils.extractCorrelationIds(rel.getCondition());
+
+ if (!corrIds.isEmpty()) {
+ inTraits =
rel.getTraitSet().replace(RewindabilityTrait.REWINDABLE);
Review comment:
inTraits are unused in this scope.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]