Header And Logo

PostgreSQL
| The world's most advanced open source database.

planner.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * planner.h
00004  *    prototypes for planner.c.
00005  *
00006  *
00007  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00008  * Portions Copyright (c) 1994, Regents of the University of California
00009  *
00010  * src/include/optimizer/planner.h
00011  *
00012  *-------------------------------------------------------------------------
00013  */
00014 #ifndef PLANNER_H
00015 #define PLANNER_H
00016 
00017 #include "nodes/plannodes.h"
00018 #include "nodes/relation.h"
00019 
00020 
00021 /* Hook for plugins to get control in planner() */
00022 typedef PlannedStmt *(*planner_hook_type) (Query *parse,
00023                                                        int cursorOptions,
00024                                                   ParamListInfo boundParams);
00025 extern PGDLLIMPORT planner_hook_type planner_hook;
00026 
00027 
00028 extern PlannedStmt *planner(Query *parse, int cursorOptions,
00029         ParamListInfo boundParams);
00030 extern PlannedStmt *standard_planner(Query *parse, int cursorOptions,
00031                  ParamListInfo boundParams);
00032 
00033 extern Plan *subquery_planner(PlannerGlobal *glob, Query *parse,
00034                  PlannerInfo *parent_root,
00035                  bool hasRecursion, double tuple_fraction,
00036                  PlannerInfo **subroot);
00037 
00038 extern void add_tlist_costs_to_plan(PlannerInfo *root, Plan *plan,
00039                                     List *tlist);
00040 
00041 extern bool is_dummy_plan(Plan *plan);
00042 
00043 extern Expr *expression_planner(Expr *expr);
00044 
00045 extern Expr *preprocess_phv_expression(PlannerInfo *root, Expr *expr);
00046 
00047 extern bool plan_cluster_use_sort(Oid tableOid, Oid indexOid);
00048 
00049 #endif   /* PLANNER_H */