1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-14 08:21:07 +03:00

Teach grammar and parser about aggregate(DISTINCT ...). No implementation

yet, but at least we can give a better error message:
regression=> select count(distinct f1) from int4_tbl;
ERROR:  aggregate(DISTINCT ...) is not implemented yet
instead of 'parser: parse error at or near distinct'.
This commit is contained in:
Tom Lane
1999-12-10 07:37:35 +00:00
parent ecba5d308c
commit 18c3000286
11 changed files with 220 additions and 114 deletions

View File

@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
* $Id: parse_agg.h,v 1.12 1999/07/15 23:04:01 momjian Exp $
* $Id: parse_agg.h,v 1.13 1999/12/10 07:37:33 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -18,7 +18,8 @@
extern void AddAggToParseState(ParseState *pstate, Aggref *aggref);
extern void parseCheckAggregates(ParseState *pstate, Query *qry);
extern Aggref *ParseAgg(ParseState *pstate, char *aggname, Oid basetype,
List *target, int precedence);
List *args, bool agg_star, bool agg_distinct,
int precedence);
extern void agg_error(char *caller, char *aggname, Oid basetypeID);
#endif /* PARSE_AGG_H */