Class PruneUnionColumns
java.lang.Object
io.trino.sql.planner.iterative.rule.ProjectOffPushDownRule<UnionNode>
io.trino.sql.planner.iterative.rule.PruneUnionColumns
- All Implemented Interfaces:
Rule<ProjectNode>
Transforms
- Project (a)
- Union
output mappings: {a->c, a->e, b->d, b->f}
- Source (c, d)
- Source (e, f)
into:
- Project (a)
- Union
output mappings: {a->c, a->e}
- Source (c, d)
- Source (e, f)
Note: as a result of this rule, the UnionNode's sources
are eligible for pruning outputs. This is accomplished
by PruneUnionSourceColumns rule.-
Nested Class Summary
Nested classes/interfaces inherited from interface io.trino.sql.planner.iterative.Rule
Rule.Context, Rule.Result -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionpushDownProjectOff(Rule.Context context, UnionNode unionNode, Set<Symbol> referencedOutputs) Methods inherited from class io.trino.sql.planner.iterative.rule.ProjectOffPushDownRule
apply, getPattern
-
Constructor Details
-
PruneUnionColumns
public PruneUnionColumns()
-
-
Method Details
-
pushDownProjectOff
protected Optional<PlanNode> pushDownProjectOff(Rule.Context context, UnionNode unionNode, Set<Symbol> referencedOutputs) - Specified by:
pushDownProjectOffin classProjectOffPushDownRule<UnionNode>
-