1 /*-------------------------------------------------------------------------
4 * prototypes for files in optimizer/prep/
7 * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
8 * Portions Copyright (c) 1994, Regents of the University of California
10 * $PostgreSQL: pgsql/src/include/optimizer/prep.h,v 1.43 2003/12/28 21:57:37 tgl Exp $
12 *-------------------------------------------------------------------------
17 #include "nodes/parsenodes.h"
18 #include "nodes/plannodes.h"
19 #include "nodes/relation.h"
23 * prototypes for prepjointree.c
25 extern int from_collapse_limit;
26 extern int join_collapse_limit;
28 extern Node *pull_up_IN_clauses(Query *parse, Node *node);
29 extern Node *pull_up_subqueries(Query *parse, Node *jtnode,
30 bool below_outer_join);
31 extern void reduce_outer_joins(Query *parse);
32 extern Node *simplify_jointree(Query *parse, Node *jtnode);
33 extern Relids get_relids_in_jointree(Node *jtnode);
34 extern Relids get_relids_for_join(Query *parse, int joinrelid);
37 * prototypes for prepqual.c
39 extern Expr *canonicalize_qual(Expr *qual);
40 extern Node *flatten_andors(Node *node);
43 * prototypes for preptlist.c
45 extern List *preprocess_targetlist(List *tlist, int command_type,
46 Index result_relation, List *range_table);
49 * prototypes for prepunion.c
51 extern Plan *plan_set_operations(Query *parse);
53 extern List *find_all_inheritors(Oid parentrel);
55 extern List *expand_inherited_rtentry(Query *parse, Index rti,
58 extern Node *adjust_inherited_attrs(Node *node,
59 Index old_rt_index, Oid old_relid,
60 Index new_rt_index, Oid new_relid);