1997-11-25 22:07:18 +00:00
|
|
|
/*-------------------------------------------------------------------------
|
|
|
|
*
|
|
|
|
* parse_clause.h
|
2003-03-22 01:49:38 +00:00
|
|
|
* handle clauses in parser
|
1997-11-25 22:07:18 +00:00
|
|
|
*
|
|
|
|
*
|
2009-01-01 17:24:05 +00:00
|
|
|
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
|
2000-01-26 05:58:53 +00:00
|
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
1997-11-25 22:07:18 +00:00
|
|
|
*
|
2009-01-01 17:24:05 +00:00
|
|
|
* $PostgreSQL: pgsql/src/include/parser/parse_clause.h,v 1.54 2009/01/01 17:24:00 momjian Exp $
|
1997-11-25 22:07:18 +00:00
|
|
|
*
|
|
|
|
*-------------------------------------------------------------------------
|
|
|
|
*/
|
|
|
|
#ifndef PARSE_CLAUSE_H
|
|
|
|
#define PARSE_CLAUSE_H
|
|
|
|
|
1999-07-15 23:04:24 +00:00
|
|
|
#include "parser/parse_node.h"
|
1997-11-25 22:07:18 +00:00
|
|
|
|
2001-02-14 21:35:07 +00:00
|
|
|
extern void transformFromClause(ParseState *pstate, List *frmList);
|
2002-03-22 02:56:37 +00:00
|
|
|
extern int setTargetTable(ParseState *pstate, RangeVar *relation,
|
2004-01-14 23:01:55 +00:00
|
|
|
bool inh, bool alsoSource, AclMode requiredPerms);
|
2001-01-05 06:34:23 +00:00
|
|
|
extern bool interpretInhOption(InhOption inhOpt);
|
2006-07-03 22:45:41 +00:00
|
|
|
extern bool interpretOidsOption(List *defList);
|
2003-06-16 02:03:38 +00:00
|
|
|
|
2003-07-03 19:07:54 +00:00
|
|
|
extern Node *transformWhereClause(ParseState *pstate, Node *clause,
|
2003-08-04 00:43:34 +00:00
|
|
|
const char *constructName);
|
2003-07-03 19:07:54 +00:00
|
|
|
extern Node *transformLimitClause(ParseState *pstate, Node *clause,
|
2003-08-04 00:43:34 +00:00
|
|
|
const char *constructName);
|
1998-09-01 04:40:42 +00:00
|
|
|
extern List *transformGroupClause(ParseState *pstate, List *grouplist,
|
2008-12-28 18:54:01 +00:00
|
|
|
List **targetlist, List *sortClause,
|
|
|
|
bool isPartition);
|
1999-08-21 03:49:17 +00:00
|
|
|
extern List *transformSortClause(ParseState *pstate, List *orderlist,
|
2004-05-23 17:10:54 +00:00
|
|
|
List **targetlist, bool resolveUnknown);
|
2008-12-28 18:54:01 +00:00
|
|
|
|
|
|
|
extern List *transformWindowDefinitions(ParseState *pstate,
|
|
|
|
List *windowdefs,
|
|
|
|
List **targetlist);
|
|
|
|
|
2008-08-02 21:32:01 +00:00
|
|
|
extern List *transformDistinctClause(ParseState *pstate,
|
|
|
|
List **targetlist, List *sortClause);
|
|
|
|
extern List *transformDistinctOnClause(ParseState *pstate, List *distinctlist,
|
2008-07-31 22:47:56 +00:00
|
|
|
List **targetlist, List *sortClause);
|
1999-08-21 03:49:17 +00:00
|
|
|
|
|
|
|
extern Index assignSortGroupRef(TargetEntry *tle, List *tlist);
|
2007-01-09 02:14:16 +00:00
|
|
|
extern bool targetIsInSortList(TargetEntry *tle, Oid sortop, List *sortList);
|
2001-10-28 06:26:15 +00:00
|
|
|
|
2001-11-05 17:46:40 +00:00
|
|
|
#endif /* PARSE_CLAUSE_H */
|