aboutsummaryrefslogtreecommitdiff
path: root/src/include/nodes/plannodes.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/nodes/plannodes.h')
-rw-r--r--src/include/nodes/plannodes.h32
1 files changed, 6 insertions, 26 deletions
diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h
index ae224cfa314..5961f2c9884 100644
--- a/src/include/nodes/plannodes.h
+++ b/src/include/nodes/plannodes.h
@@ -714,23 +714,17 @@ typedef struct Group
* we are using the Agg node to implement hash-based grouping.)
* ---------------
*/
-typedef enum AggStrategy
-{
- AGG_PLAIN, /* simple agg across all input rows */
- AGG_SORTED, /* grouped agg, input must be sorted */
- AGG_HASHED /* grouped agg, use internal hashtable */
-} AggStrategy;
-
typedef struct Agg
{
Plan plan;
- AggStrategy aggstrategy;
- int numCols; /* number of grouping columns */
- AttrNumber *grpColIdx; /* their indexes in the target list */
+ AggStrategy aggstrategy; /* basic strategy, see nodes.h */
bool combineStates; /* input tuples contain transition states */
bool finalizeAggs; /* should we call the finalfn on agg states? */
+ int numCols; /* number of grouping columns */
+ AttrNumber *grpColIdx; /* their indexes in the target list */
Oid *grpOperators; /* equality operators to compare with */
long numGroups; /* estimated number of groups in input */
+ /* Note: the planner only provides numGroups in AGG_HASHED case */
List *groupingSets; /* grouping sets to use */
List *chain; /* chained Agg/Sort nodes */
} Agg;
@@ -802,25 +796,11 @@ typedef struct Hash
* setop node
* ----------------
*/
-typedef enum SetOpCmd
-{
- SETOPCMD_INTERSECT,
- SETOPCMD_INTERSECT_ALL,
- SETOPCMD_EXCEPT,
- SETOPCMD_EXCEPT_ALL
-} SetOpCmd;
-
-typedef enum SetOpStrategy
-{
- SETOP_SORTED, /* input must be sorted */
- SETOP_HASHED /* use internal hashtable */
-} SetOpStrategy;
-
typedef struct SetOp
{
Plan plan;
- SetOpCmd cmd; /* what to do */
- SetOpStrategy strategy; /* how to do it */
+ SetOpCmd cmd; /* what to do, see nodes.h */
+ SetOpStrategy strategy; /* how to do it, see nodes.h */
int numCols; /* number of columns to check for
* duplicate-ness */
AttrNumber *dupColIdx; /* their indexes in the target list */