PostgreSQL Source Code  git master
subselect.h
Go to the documentation of this file.
1 /*-------------------------------------------------------------------------
2  *
3  * subselect.h
4  * Planning routines for subselects.
5  *
6  * Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
7  * Portions Copyright (c) 1994, Regents of the University of California
8  *
9  * src/include/optimizer/subselect.h
10  *
11  *-------------------------------------------------------------------------
12  */
13 #ifndef SUBSELECT_H
14 #define SUBSELECT_H
15 
16 #include "nodes/pathnodes.h"
17 #include "nodes/plannodes.h"
18 
19 extern void SS_process_ctes(PlannerInfo *root);
21  SubLink *sublink,
22  Relids available_rels);
24  SubLink *sublink,
25  bool under_not,
26  Relids available_rels);
28 extern Node *SS_process_sublinks(PlannerInfo *root, Node *expr, bool isQual);
30 extern void SS_charge_for_initplans(PlannerInfo *root, RelOptInfo *final_rel);
31 extern void SS_compute_initplan_cost(List *init_plans,
32  Cost *initplan_cost_p,
33  bool *unsafe_initplans_p);
35 extern void SS_finalize_plan(PlannerInfo *root, Plan *plan);
37  Oid resulttype, int32 resulttypmod,
38  Oid resultcollation);
40  PlannerInfo *subroot, Plan *plan,
41  Param *prm);
42 
43 #endif /* SUBSELECT_H */
int32_t int32
Definition: c.h:481
double Cost
Definition: nodes.h:251
#define plan(x)
Definition: pg_regress.c:161
unsigned int Oid
Definition: postgres_ext.h:31
tree ctl root
Definition: radixtree.h:1888
Definition: pg_list.h:54
Definition: nodes.h:129
void SS_process_ctes(PlannerInfo *root)
Definition: subselect.c:878
JoinExpr * convert_ANY_sublink_to_join(PlannerInfo *root, SubLink *sublink, Relids available_rels)
Definition: subselect.c:1251
void SS_identify_outer_params(PlannerInfo *root)
Definition: subselect.c:2091
void SS_finalize_plan(PlannerInfo *root, Plan *plan)
Definition: subselect.c:2273
Node * SS_replace_correlation_vars(PlannerInfo *root, Node *expr)
Definition: subselect.c:1889
Param * SS_make_initplan_output_param(PlannerInfo *root, Oid resulttype, int32 resulttypmod, Oid resultcollation)
Definition: subselect.c:3018
JoinExpr * convert_EXISTS_sublink_to_join(PlannerInfo *root, SubLink *sublink, bool under_not, Relids available_rels)
Definition: subselect.c:1368
void SS_attach_initplans(PlannerInfo *root, Plan *plan)
Definition: subselect.c:2258
Node * SS_process_sublinks(PlannerInfo *root, Node *expr, bool isQual)
Definition: subselect.c:1938
void SS_compute_initplan_cost(List *init_plans, Cost *initplan_cost_p, bool *unsafe_initplans_p)
Definition: subselect.c:2217
void SS_charge_for_initplans(PlannerInfo *root, RelOptInfo *final_rel)
Definition: subselect.c:2153
void SS_make_initplan_from_plan(PlannerInfo *root, PlannerInfo *subroot, Plan *plan, Param *prm)
Definition: subselect.c:3034