aboutsummaryrefslogtreecommitdiff
path: root/src/include/nodes/relation.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/nodes/relation.h')
-rw-r--r--src/include/nodes/relation.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/include/nodes/relation.h b/src/include/nodes/relation.h
index 78b03e024e8..f6592697e44 100644
--- a/src/include/nodes/relation.h
+++ b/src/include/nodes/relation.h
@@ -46,6 +46,20 @@ typedef struct QualCost
Cost per_tuple; /* per-evaluation cost */
} QualCost;
+/*
+ * Costing aggregate function execution requires these statistics about
+ * the aggregates to be executed by a given Agg node. Note that transCost
+ * includes the execution costs of the aggregates' input expressions.
+ */
+typedef struct AggClauseCosts
+{
+ int numAggs; /* total number of aggregate functions */
+ int numOrderedAggs; /* number that use DISTINCT or ORDER BY */
+ QualCost transCost; /* total per-input-row execution costs */
+ Cost finalCost; /* total costs of agg final functions */
+ Size transitionSpace; /* space for pass-by-ref transition data */
+} AggClauseCosts;
+
/*----------
* PlannerGlobal