public abstract class HiveSubQueryRemoveRule
extends org.apache.calcite.plan.RelOptRule
Sub-queries are represented by RexSubQuery
expressions.
A sub-query may or may not be correlated. If a sub-query is correlated,
the wrapped RelNode
will contain a RexCorrelVariable
before
the rewrite, and the product of the rewrite will be a Correlate
.
The Correlate can be removed using RelDecorrelator
.
Modifier and Type | Field and Description |
---|---|
static HiveSubQueryRemoveRule |
FILTER |
static HiveSubQueryRemoveRule |
PROJECT |
Modifier and Type | Method and Description |
---|---|
protected org.apache.calcite.rex.RexNode |
apply(org.apache.calcite.rex.RexSubQuery e,
Set<org.apache.calcite.rel.core.CorrelationId> variablesSet,
org.apache.calcite.plan.RelOptUtil.Logic logic,
HiveSubQRemoveRelBuilder builder,
int inputCount,
int offset,
boolean isCorrScalarAgg) |
public static final HiveSubQueryRemoveRule PROJECT
public static final HiveSubQueryRemoveRule FILTER
protected org.apache.calcite.rex.RexNode apply(org.apache.calcite.rex.RexSubQuery e, Set<org.apache.calcite.rel.core.CorrelationId> variablesSet, org.apache.calcite.plan.RelOptUtil.Logic logic, HiveSubQRemoveRelBuilder builder, int inputCount, int offset, boolean isCorrScalarAgg)
Copyright © 2021 The Apache Software Foundation. All rights reserved.