aboutsummaryrefslogtreecommitdiff
path: root/src/include/parser
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2003-06-06 15:04:03 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2003-06-06 15:04:03 +0000
commite649796f128bd8702ba5744d36f4e8cb81f0b754 (patch)
tree050eda51ad8f0298731316ccf61db2c01a2863a3 /src/include/parser
parent2c93861f7cef99b4613abd37ed7e4c15a95754b4 (diff)
downloadpostgresql-e649796f128bd8702ba5744d36f4e8cb81f0b754.tar.gz
postgresql-e649796f128bd8702ba5744d36f4e8cb81f0b754.zip
Implement outer-level aggregates to conform to the SQL spec, with
extensions to support our historical behavior. An aggregate belongs to the closest query level of any of the variables in its argument, or the current query level if there are no variables (e.g., COUNT(*)). The implementation involves adding an agglevelsup field to Aggref, and treating outer aggregates like outer variables at planning time.
Diffstat (limited to 'src/include/parser')
-rw-r--r--src/include/parser/parse_agg.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/include/parser/parse_agg.h b/src/include/parser/parse_agg.h
index 111d726bc9c..bc1e601cc22 100644
--- a/src/include/parser/parse_agg.h
+++ b/src/include/parser/parse_agg.h
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: parse_agg.h,v 1.25 2003/01/17 03:25:04 tgl Exp $
+ * $Id: parse_agg.h,v 1.26 2003/06/06 15:04:03 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -15,6 +15,8 @@
#include "parser/parse_node.h"
+extern void transformAggregateCall(ParseState *pstate, Aggref *agg);
+
extern void parseCheckAggregates(ParseState *pstate, Query *qry);
#endif /* PARSE_AGG_H */