Class ImplementFilteredAggregations

  • All Implemented Interfaces:
    Rule<AggregationNode>

    public class ImplementFilteredAggregations
    extends Object
    implements Rule<AggregationNode>
    Implements filtered aggregations by transforming plans of the following shape:
     - Aggregation
            F1(...) FILTER (WHERE C1(...)),
            F2(...) FILTER (WHERE C2(...))
         - X
     
    into
     - Aggregation
            F1(...) mask ($0)
            F2(...) mask ($1)
         - Filter(mask ($0) OR mask ($1))
         - Project
                <identity projections for existing fields>
                $0 = C1(...)
                $1 = C2(...)
             - X