class |
AddIntermediateAggregations |
Adds INTERMEDIATE aggregations between an un-grouped FINAL aggregation and its preceding
PARTIAL aggregation.
|
class |
ApplyPreferredTableExecutePartitioning |
|
class |
ApplyPreferredTableWriterPartitioning |
Rule verifies if preconditions for using preferred write partitioning are met:
- expected number of partitions to be written (based on table stat) is greater
than or equal to preferred_write_partitioning_min_number_of_partitions session property,
- use_preferred_write_partitioning is set to true.
|
class |
ApplyTableScanRedirection |
|
class |
CreatePartialTopN |
|
class |
DecorrelateInnerUnnestWithGlobalAggregation |
This rule finds correlated UnnestNode in CorrelatedJoinNode's subquery and folds
them into UnnestNode representing LEFT JOIN UNNEST.
|
class |
DecorrelateLeftUnnestWithGlobalAggregation |
This rule finds correlated UnnestNode in CorrelatedJoinNode's subquery and folds
them into UnnestNode representing LEFT JOIN UNNEST.
|
class |
DecorrelateUnnest |
This rule decorrelates plans with correlated UnnestNode and optional EnforceSingleRowNode,
optional LimitNode, optional TopNNode and optional projections in the subquery.
|
class |
DetermineJoinDistributionType |
|
class |
DetermineSemiJoinDistributionType |
This rule must run after the distribution type has already been set for delete queries,
since semi joins in delete queries must be replicated.
|
class |
DetermineTableScanNodePartitioning |
|
class |
EliminateCrossJoins |
|
class |
EvaluateEmptyIntersect |
Converts an Intersect node with at least one empty branch to an empty Values node.
|
class |
EvaluateZeroSample |
Replaces 0% sample node with empty values node.
|
class |
ExtractDereferencesFromFilterAboveScan |
Transforms:
|
static class |
ExtractSpatialJoins.ExtractSpatialInnerJoin |
|
static class |
ExtractSpatialJoins.ExtractSpatialLeftJoin |
|
static class |
GatherAndMergeWindows.MergeAdjacentWindowsOverProjects |
|
static class |
GatherAndMergeWindows.SwapAdjacentWindowsBySpecifications |
|
class |
ImplementBernoulliSampleAsFilter |
Transforms:
|
class |
ImplementExceptAll |
Implement EXCEPT ALL using union, window and filter.
|
class |
ImplementExceptDistinctAsUnion |
Converts EXCEPT DISTINCT queries into UNION ALL..GROUP BY...WHERE
E.g.:
|
class |
ImplementFilteredAggregations |
Implements filtered aggregations by transforming plans of the following shape:
|
class |
ImplementIntersectAll |
Implement INTERSECT ALL using union, window and filter.
|
class |
ImplementIntersectDistinctAsUnion |
Converts INTERSECT DISTINCT queries into UNION ALL..GROUP BY...WHERE
E.g.:
|
class |
ImplementLimitWithTies |
Transforms:
|
class |
ImplementOffset |
Transforms:
|
class |
InlineProjectIntoFilter |
Replace filter predicate conjuncts with underlying project expressions.
|
class |
InlineProjections |
Inlines expressions from a child project node into a parent project node
as long as they are simple constants, or they are referenced only once (to
avoid introducing duplicate computation) and the references don't appear
within a TRY block (to avoid changing semantics).
|
class |
MergeExcept |
|
class |
MergeFilters |
|
class |
MergeIntersect |
Transforms:
|
class |
MergeLimitOverProjectWithSort |
Transforms:
|
class |
MergeLimits |
This rule handles both LimitNode with ties and LimitNode without ties.
|
class |
MergeLimitWithDistinct |
|
class |
MergeLimitWithSort |
|
class |
MergeLimitWithTopN |
This rule handles both LimitNode with ties and LimitNode without ties.
|
static class |
MergePatternRecognitionNodes.MergePatternRecognitionNodesWithoutProject |
|
static class |
MergePatternRecognitionNodes.MergePatternRecognitionNodesWithProject |
|
class |
MergeProjectWithValues |
Transforms:
|
class |
MergeUnion |
Transforms:
|
class |
MultipleDistinctAggregationToMarkDistinct |
Implements distinct aggregations with different inputs by transforming plans of the following shape:
|
class |
OptimizeDuplicateInsensitiveJoins |
For empty aggregations duplicate input rows can be skipped.
|
class |
OptimizeRowPattern |
|
class |
ProjectOffPushDownRule<N extends PlanNode> |
|
class |
PruneAggregationColumns |
|
class |
PruneAggregationSourceColumns |
|
class |
PruneApplyColumns |
This rule restricts the outputs of ApplyNode's input and subquery
based on which ApplyNode's output symbols are referenced.
|
class |
PruneApplyCorrelation |
This rule updates ApplyNode's correlation list.
|
class |
PruneApplySourceColumns |
This rule restricts outputs of ApplyNode's subquery to include only the symbols
needed for subqueryAssignments.
|
class |
PruneAssignUniqueIdColumns |
|
class |
PruneCorrelatedJoinColumns |
This rule restricts the outputs of CorrelatedJoinNode's input and subquery
based on which CorrelatedJoinNode's output symbols are referenced.
|
class |
PruneCorrelatedJoinCorrelation |
This rule updates CorrelatedJoinNode's correlation list.
|
class |
PruneCountAggregationOverScalar |
A count over a subquery can be reduced to a VALUES(1) provided
the subquery is a scalar
|
class |
PruneDeleteSourceColumns |
|
class |
PruneDistinctAggregation |
|
class |
PruneDistinctLimitSourceColumns |
|
class |
PruneEnforceSingleRowColumns |
|
class |
PruneExceptSourceColumns |
|
class |
PruneExchangeColumns |
This rule restricts the outputs of ExchangeNode based on which
ExchangeNode's output symbols are either referenced by the
parent node or used for partitioning, ordering or as a hash
symbol by the ExchangeNode.
|
class |
PruneExchangeSourceColumns |
|
class |
PruneExplainAnalyzeSourceColumns |
|
class |
PruneFilterColumns |
|
class |
PruneGroupIdColumns |
This rule prunes GroupIdNode's aggregationArguments.
|
class |
PruneGroupIdSourceColumns |
|
class |
PruneIndexJoinColumns |
|
class |
PruneIndexSourceColumns |
|
class |
PruneIntersectSourceColumns |
|
class |
PruneJoinChildrenColumns |
Joins support output symbol selection, so make any project-off of child columns explicit in project nodes.
|
class |
PruneJoinColumns |
Joins support output symbol selection, so absorb any project-off into the node.
|
class |
PruneLimitColumns |
|
class |
PruneMarkDistinctColumns |
|
class |
PruneOffsetColumns |
|
class |
PruneOrderByInAggregation |
|
class |
PruneOutputSourceColumns |
|
class |
PrunePattenRecognitionColumns |
|
class |
PrunePatternRecognitionSourceColumns |
This rule restricts the inputs to PatternRecognitionNode
based on which symbols are used by the inner structures
of the PatternRecognitionNode.
|
class |
PruneProjectColumns |
|
class |
PruneRowNumberColumns |
|
class |
PruneSampleColumns |
|
class |
PruneSemiJoinColumns |
|
class |
PruneSemiJoinFilteringSourceColumns |
|
class |
PruneSortColumns |
|
class |
PruneSpatialJoinChildrenColumns |
|
class |
PruneSpatialJoinColumns |
Spatial joins support output symbol selection, so absorb any project-off into the node.
|
class |
PruneTableExecuteSourceColumns |
|
class |
PruneTableScanColumns |
This is a special case of PushProjectionIntoTableScan that performs only column pruning.
|
class |
PruneTableWriterSourceColumns |
|
class |
PruneTopNColumns |
|
class |
PruneTopNRankingColumns |
|
class |
PruneUnionColumns |
Transforms
|
class |
PruneUnionSourceColumns |
|
class |
PruneUnnestColumns |
Absorb pruning projection into the node.
|
class |
PruneUnnestSourceColumns |
|
class |
PruneUpdateSourceColumns |
|
class |
PruneValuesColumns |
|
class |
PruneWindowColumns |
|
class |
PushAggregationIntoTableScan |
|
class |
PushAggregationThroughOuterJoin |
This optimizer pushes aggregations below outer joins when: the aggregation
is on top of the outer join, it groups by all columns in the outer table, and
the outer rows are guaranteed to be distinct.
|
class |
PushDeleteIntoConnector |
|
class |
PushDistinctLimitIntoTableScan |
|
class |
PushDownDereferencesThroughAssignUniqueId |
Transforms:
|
class |
PushDownDereferencesThroughLimit |
Transforms:
|
class |
PushDownDereferencesThroughMarkDistinct |
Transforms:
|
class |
PushDownDereferencesThroughRowNumber |
Transforms:
|
class |
PushDownDereferencesThroughSort |
Transforms:
|
class |
PushDownDereferencesThroughTopN |
Transforms:
|
class |
PushDownDereferencesThroughTopNRanking |
Transforms:
|
class |
PushDownDereferencesThroughWindow |
Transforms:
|
class |
PushDownDereferenceThroughFilter |
Transforms:
|
class |
PushDownDereferenceThroughJoin |
Transforms:
|
class |
PushDownDereferenceThroughProject |
Transforms:
|
class |
PushDownDereferenceThroughSemiJoin |
Transforms:
|
class |
PushDownDereferenceThroughUnnest |
Transforms:
|
class |
PushdownFilterIntoRowNumber |
|
class |
PushdownFilterIntoWindow |
|
class |
PushdownLimitIntoRowNumber |
|
class |
PushdownLimitIntoWindow |
|
class |
PushDownProjectionsFromPatternRecognition |
Aggregate functions in pattern recognition context have special semantics.
|
class |
PushJoinIntoTableScan |
|
class |
PushLimitIntoTableScan |
|
class |
PushLimitThroughMarkDistinct |
|
class |
PushLimitThroughOffset |
Transforms:
|
class |
PushLimitThroughOuterJoin |
Transforms:
|
class |
PushLimitThroughProject |
|
class |
PushLimitThroughSemiJoin |
|
class |
PushLimitThroughUnion |
Transforms:
|
class |
PushOffsetThroughProject |
Transforms:
|
class |
PushPartialAggregationThroughExchange |
|
class |
PushPartialAggregationThroughJoin |
|
class |
PushPredicateIntoTableScan |
These rules should not be run after AddExchanges so as not to overwrite the TableLayout
chosen by AddExchanges
|
class |
PushPredicateThroughProjectIntoRowNumber |
This rule pushes filter predicate concerning row number symbol into RowNumberNode
by modifying maxRowCountPerPartition.
|
class |
PushPredicateThroughProjectIntoWindow |
This rule pushes filter predicate concerning a ranking symbol into WindowNode
by converting it into TopNRankingNode.
|
class |
PushProjectionIntoTableScan |
|
class |
PushProjectionThroughExchange |
Transforms:
|
class |
PushProjectionThroughUnion |
|
class |
PushRemoteExchangeThroughAssignUniqueId |
Pushes RemoteExchange node down through the AssignUniqueId to preserve
partitioned_on(unique) and grouped(unique) properties for the output of
the AssignUniqueId.
|
class |
PushSampleIntoTableScan |
|
class |
PushTableWriteThroughUnion |
|
class |
PushTopNIntoTableScan |
|
class |
PushTopNThroughOuterJoin |
Transforms:
|
class |
PushTopNThroughProject |
Transforms:
|
class |
PushTopNThroughUnion |
|
class |
RemoveAggregationInSemiJoin |
Remove the aggregation node that produces distinct rows from the Filtering source of a Semi join.
|
class |
RemoveEmptyExceptBranches |
Removes branches from an ExceptNode that are guaranteed to produce 0 rows.
|
class |
RemoveEmptyTableExecute |
If the predicate for a table execute is optimized to false, the target table scan
of table execute will be replaced with an empty values node.
|
class |
RemoveEmptyUnionBranches |
Removes branches from a UnionNode that are guaranteed to produce 0 rows.
|
class |
RemoveFullSample |
Removes 100% sample nodes.
|
class |
RemoveRedundantDistinctLimit |
Replace DistinctLimit node
1.
|
class |
RemoveRedundantEnforceSingleRowNode |
|
class |
RemoveRedundantExists |
Given:
|
class |
RemoveRedundantIdentityProjections |
Removes projection nodes that only perform non-renaming identity projections
|
class |
RemoveRedundantJoin |
|
class |
RemoveRedundantLimit |
Remove Limit node when the subplan is guaranteed to produce fewer rows than the limit and
replace the plan with empty values if the limit count is 0.
|
class |
RemoveRedundantOffset |
Remove Offset node and its subplan when the subplan is guaranteed to produce no more rows than the offset
and replace the plan with empty values.
|
class |
RemoveRedundantSort |
|
class |
RemoveRedundantSortBelowLimitWithTies |
This rule removes SortNode being a source of LimitNode with ties.
|
class |
RemoveRedundantTableScanPredicate |
|
class |
RemoveRedundantTopN |
Replace TopN node
1.
|
class |
RemoveTrivialFilters |
|
class |
RemoveUnreferencedScalarApplyNodes |
|
class |
RemoveUnreferencedScalarSubqueries |
|
class |
ReorderJoins |
|
class |
ReplaceJoinOverConstantWithProject |
This rule transforms plans with join where one of the sources is
a single-row ValuesNode, and the join condition is `on true`.
|
class |
ReplaceRedundantJoinWithProject |
This rule is complementary to RemoveRedundantJoin.
|
class |
ReplaceRedundantJoinWithSource |
This rule transforms plans with joins, where:
- one of the sources is scalar and produces no output symbols.
|
class |
ReplaceWindowWithRowNumber |
|
class |
RewriteSpatialPartitioningAggregation |
Re-writes spatial_partitioning(geometry) aggregations into spatial_partitioning(envelope, partition_count)
on top of ST_Envelope(geometry) projection, e.g.
|
class |
SimplifyCountOverConstant |
|
class |
SimplifyFilterPredicate |
Simplify conditional expressions in filter predicate.
|
class |
SingleDistinctAggregationToGroupBy |
Implements distinct aggregations with similar inputs by transforming plans of the following shape:
|
class |
TransformCorrelatedDistinctAggregationWithoutProjection |
This rule decorrelates a correlated subquery of LEFT correlated join with distinct operator (grouped aggregation with no aggregation assignments)
It is similar to TransformCorrelatedDistinctAggregationWithProjection rule, but does not support projection over aggregation in the subquery
|
class |
TransformCorrelatedDistinctAggregationWithProjection |
This rule decorrelates a correlated subquery of LEFT correlated join with distinct operator (grouped aggregation with no aggregation assignments)
|
class |
TransformCorrelatedGlobalAggregationWithoutProjection |
This rule decorrelates a correlated subquery with:
- single global aggregation, or
- global aggregation over distinct operator (grouped aggregation with no aggregation assignments)
It is similar to TransformCorrelatedGlobalAggregationWithProjection rule, but does not support projection over aggregation in the subquery
|
class |
TransformCorrelatedGlobalAggregationWithProjection |
This rule decorrelates a correlated subquery of LEFT or INNER correlated join with:
- single global aggregation, or
- global aggregation over distinct operator (grouped aggregation with no aggregation assignments)
|
class |
TransformCorrelatedGroupedAggregationWithoutProjection |
This rule decorrelates a correlated subquery of INNER correlated join with:
- single grouped aggregation, or
- grouped aggregation over distinct operator (grouped aggregation with no aggregation assignments)
It is similar to TransformCorrelatedGroupedAggregationWithProjection rule, but does not support projection over aggregation in the subquery
|
class |
TransformCorrelatedGroupedAggregationWithProjection |
This rule decorrelates a correlated subquery of INNER correlated join with:
- single grouped aggregation, or
- grouped aggregation over distinct operator (grouped aggregation with no aggregation assignments)
|
class |
TransformCorrelatedInPredicateToJoin |
Replaces correlated ApplyNode with InPredicate expression with SemiJoin
|
class |
TransformCorrelatedJoinToJoin |
Tries to decorrelate subquery and rewrite it using normal join.
|
class |
TransformCorrelatedScalarSubquery |
Scalar filter scan query is something like:
|
class |
TransformCorrelatedSingleRowSubqueryToProject |
This optimizer can rewrite correlated single row subquery to projection in a way described here:
From:
|
class |
TransformExistsApplyToCorrelatedJoin |
EXISTS is modeled as (if correlated predicates are equality comparisons):
|
class |
TransformFilteringSemiJoinToInnerJoin |
Rewrite filtering semi-join to inner join.
|
class |
TransformUncorrelatedInPredicateSubqueryToSemiJoin |
This optimizers looks for InPredicate expressions in ApplyNodes and replaces the nodes with SemiJoin nodes.
|
class |
TransformUncorrelatedSubqueryToJoin |
|
class |
UnwrapSingleColumnRowInApply |
Given x::row(t) and y::row(t), converts assignments of the form
|