postgresql/src/include/optimizer/restrictinfo.h

48 lines
1.7 KiB
C
Raw Normal View History

/*-------------------------------------------------------------------------
*
* restrictinfo.h
* prototypes for restrictinfo.c.
*
*
2010-01-02 17:58:17 +01:00
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
2010-01-02 17:58:17 +01:00
* $PostgreSQL: pgsql/src/include/optimizer/restrictinfo.h,v 1.46 2010/01/02 16:58:07 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#ifndef RESTRICTINFO_H
#define RESTRICTINFO_H
#include "nodes/relation.h"
/* Convenience macro for the common case of a valid-everywhere qual */
#define make_simple_restrictinfo(clause) \
make_restrictinfo(clause, true, false, false, NULL, NULL)
extern RestrictInfo *make_restrictinfo(Expr *clause,
2005-10-15 04:49:52 +02:00
bool is_pushed_down,
bool outerjoin_delayed,
bool pseudoconstant,
Relids required_relids,
Relids nullable_relids);
extern List *make_restrictinfo_from_bitmapqual(Path *bitmapqual,
2005-10-15 04:49:52 +02:00
bool is_pushed_down,
bool include_predicates);
extern List *make_restrictinfos_from_actual_clauses(PlannerInfo *root,
List *clause_list);
extern bool restriction_is_or_clause(RestrictInfo *restrictinfo);
extern List *get_actual_clauses(List *restrictinfo_list);
extern List *get_all_actual_clauses(List *restrictinfo_list);
extern List *extract_actual_clauses(List *restrictinfo_list,
2006-10-04 02:30:14 +02:00
bool pseudoconstant);
extern void extract_actual_join_clauses(List *restrictinfo_list,
List **joinquals,
List **otherquals);
extern List *select_nonredundant_join_clauses(PlannerInfo *root,
2003-08-04 02:43:34 +02:00
List *restrictinfo_list,
Path *inner_path);
#endif /* RESTRICTINFO_H */