work in progress, cleaned up the directories and split them up into folder which make more sense, Still need to compile libvitaboy and all the tools

This commit is contained in:
Jip 2024-05-13 18:38:21 +02:00
parent 66ce473514
commit 948bd8474c
1786 changed files with 571812 additions and 15332 deletions

61
deps/libpq/include/catalog/catalog.h vendored Normal file
View file

@ -0,0 +1,61 @@
/*-------------------------------------------------------------------------
*
* catalog.h
* prototypes for functions in backend/catalog/catalog.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/catalog.h
*
*-------------------------------------------------------------------------
*/
#ifndef CATALOG_H
#define CATALOG_H
#include "catalog/catversion.h"
#include "catalog/pg_class.h"
#include "storage/relfilenode.h"
#include "utils/relcache.h"
#define OIDCHARS 10 /* max chars printed by %u */
#define TABLESPACE_VERSION_DIRECTORY "PG_" PG_MAJORVERSION "_" \
CppAsString2(CATALOG_VERSION_NO)
extern const char *forkNames[];
extern ForkNumber forkname_to_number(char *forkName);
extern int forkname_chars(const char *str, ForkNumber *);
extern char *relpathbackend(RelFileNode rnode, BackendId backend,
ForkNumber forknum);
extern char *GetDatabasePath(Oid dbNode, Oid spcNode);
/* First argument is a RelFileNodeBackend */
#define relpath(rnode, forknum) \
relpathbackend((rnode).node, (rnode).backend, (forknum))
/* First argument is a RelFileNode */
#define relpathperm(rnode, forknum) \
relpathbackend((rnode), InvalidBackendId, (forknum))
extern bool IsSystemRelation(Relation relation);
extern bool IsToastRelation(Relation relation);
extern bool IsSystemClass(Form_pg_class reltuple);
extern bool IsToastClass(Form_pg_class reltuple);
extern bool IsSystemNamespace(Oid namespaceId);
extern bool IsToastNamespace(Oid namespaceId);
extern bool IsReservedName(const char *name);
extern bool IsSharedRelation(Oid relationId);
extern Oid GetNewOid(Relation relation);
extern Oid GetNewOidWithIndex(Relation relation, Oid indexId,
AttrNumber oidcolumn);
extern Oid GetNewRelFileNode(Oid reltablespace, Relation pg_class,
char relpersistence);
#endif /* CATALOG_H */

58
deps/libpq/include/catalog/catversion.h vendored Normal file
View file

@ -0,0 +1,58 @@
/*-------------------------------------------------------------------------
*
* catversion.h
* "Catalog version number" for PostgreSQL.
*
* The catalog version number is used to flag incompatible changes in
* the PostgreSQL system catalogs. Whenever anyone changes the format of
* a system catalog relation, or adds, deletes, or modifies standard
* catalog entries in such a way that an updated backend wouldn't work
* with an old database (or vice versa), the catalog version number
* should be changed. The version number stored in pg_control by initdb
* is checked against the version number compiled into the backend at
* startup time, so that a backend can refuse to run in an incompatible
* database.
*
* The point of this feature is to provide a finer grain of compatibility
* checking than is possible from looking at the major version number
* stored in PG_VERSION. It shouldn't matter to end users, but during
* development cycles we usually make quite a few incompatible changes
* to the contents of the system catalogs, and we don't want to bump the
* major version number for each one. What we can do instead is bump
* this internal version number. This should save some grief for
* developers who might otherwise waste time tracking down "bugs" that
* are really just code-vs-database incompatibilities.
*
* The rule for developers is: if you commit a change that requires
* an initdb, you should update the catalog version number (as well as
* notifying the pghackers mailing list, which has been the informal
* practice for a long time).
*
* The catalog version number is placed here since modifying files in
* include/catalog is the most common kind of initdb-forcing change.
* But it could be used to protect any kind of incompatible change in
* database contents or layout, such as altering tuple headers.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/catversion.h
*
*-------------------------------------------------------------------------
*/
#ifndef CATVERSION_H
#define CATVERSION_H
/*
* We could use anything we wanted for version numbers, but I recommend
* following the "YYYYMMDDN" style often used for DNS zone serial numbers.
* YYYYMMDD are the date of the change, and N is the number of the change
* on that day. (Hopefully we'll never commit ten independent sets of
* catalog changes on the same day...)
*/
/* yyyymmddN */
#define CATALOG_VERSION_NO 201105231
#endif

261
deps/libpq/include/catalog/dependency.h vendored Normal file
View file

@ -0,0 +1,261 @@
/*-------------------------------------------------------------------------
*
* dependency.h
* Routines to support inter-object dependencies.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/dependency.h
*
*-------------------------------------------------------------------------
*/
#ifndef DEPENDENCY_H
#define DEPENDENCY_H
#include "nodes/parsenodes.h" /* for DropBehavior */
#include "catalog/objectaddress.h"
/*
* Precise semantics of a dependency relationship are specified by the
* DependencyType code (which is stored in a "char" field in pg_depend,
* so we assign ASCII-code values to the enumeration members).
*
* In all cases, a dependency relationship indicates that the referenced
* object may not be dropped without also dropping the dependent object.
* However, there are several subflavors:
*
* DEPENDENCY_NORMAL ('n'): normal relationship between separately-created
* objects. The dependent object may be dropped without affecting the
* referenced object. The referenced object may only be dropped by
* specifying CASCADE, in which case the dependent object is dropped too.
* Example: a table column has a normal dependency on its datatype.
*
* DEPENDENCY_AUTO ('a'): the dependent object can be dropped separately
* from the referenced object, and should be automatically dropped
* (regardless of RESTRICT or CASCADE mode) if the referenced object
* is dropped.
* Example: a named constraint on a table is made auto-dependent on
* the table, so that it will go away if the table is dropped.
*
* DEPENDENCY_INTERNAL ('i'): the dependent object was created as part
* of creation of the referenced object, and is really just a part of
* its internal implementation. A DROP of the dependent object will be
* disallowed outright (we'll tell the user to issue a DROP against the
* referenced object, instead). A DROP of the referenced object will be
* propagated through to drop the dependent object whether CASCADE is
* specified or not.
* Example: a trigger that's created to enforce a foreign-key constraint
* is made internally dependent on the constraint's pg_constraint entry.
*
* DEPENDENCY_EXTENSION ('e'): the dependent object is a member of the
* extension that is the referenced object. The dependent object can be
* dropped only via DROP EXTENSION on the referenced object. Functionally
* this dependency type acts the same as an internal dependency, but it's
* kept separate for clarity and to simplify pg_dump.
*
* DEPENDENCY_PIN ('p'): there is no dependent object; this type of entry
* is a signal that the system itself depends on the referenced object,
* and so that object must never be deleted. Entries of this type are
* created only during initdb. The fields for the dependent object
* contain zeroes.
*
* Other dependency flavors may be needed in future.
*/
typedef enum DependencyType
{
DEPENDENCY_NORMAL = 'n',
DEPENDENCY_AUTO = 'a',
DEPENDENCY_INTERNAL = 'i',
DEPENDENCY_EXTENSION = 'e',
DEPENDENCY_PIN = 'p'
} DependencyType;
/*
* There is also a SharedDependencyType enum type that determines the exact
* semantics of an entry in pg_shdepend. Just like regular dependency entries,
* any pg_shdepend entry means that the referenced object cannot be dropped
* unless the dependent object is dropped at the same time. There are some
* additional rules however:
*
* (a) For a SHARED_DEPENDENCY_PIN entry, there is no dependent object --
* rather, the referenced object is an essential part of the system. This
* applies to the initdb-created superuser. Entries of this type are only
* created by initdb; objects in this category don't need further pg_shdepend
* entries if more objects come to depend on them.
*
* (b) a SHARED_DEPENDENCY_OWNER entry means that the referenced object is
* the role owning the dependent object. The referenced object must be
* a pg_authid entry.
*
* (c) a SHARED_DEPENDENCY_ACL entry means that the referenced object is
* a role mentioned in the ACL field of the dependent object. The referenced
* object must be a pg_authid entry. (SHARED_DEPENDENCY_ACL entries are not
* created for the owner of an object; hence two objects may be linked by
* one or the other, but not both, of these dependency types.)
*
* SHARED_DEPENDENCY_INVALID is a value used as a parameter in internal
* routines, and is not valid in the catalog itself.
*/
typedef enum SharedDependencyType
{
SHARED_DEPENDENCY_PIN = 'p',
SHARED_DEPENDENCY_OWNER = 'o',
SHARED_DEPENDENCY_ACL = 'a',
SHARED_DEPENDENCY_INVALID = 0
} SharedDependencyType;
/* expansible list of ObjectAddresses (private in dependency.c) */
typedef struct ObjectAddresses ObjectAddresses;
/*
* This enum covers all system catalogs whose OIDs can appear in
* pg_depend.classId or pg_shdepend.classId.
*/
typedef enum ObjectClass
{
OCLASS_CLASS, /* pg_class */
OCLASS_PROC, /* pg_proc */
OCLASS_TYPE, /* pg_type */
OCLASS_CAST, /* pg_cast */
OCLASS_COLLATION, /* pg_collation */
OCLASS_CONSTRAINT, /* pg_constraint */
OCLASS_CONVERSION, /* pg_conversion */
OCLASS_DEFAULT, /* pg_attrdef */
OCLASS_LANGUAGE, /* pg_language */
OCLASS_LARGEOBJECT, /* pg_largeobject */
OCLASS_OPERATOR, /* pg_operator */
OCLASS_OPCLASS, /* pg_opclass */
OCLASS_OPFAMILY, /* pg_opfamily */
OCLASS_AMOP, /* pg_amop */
OCLASS_AMPROC, /* pg_amproc */
OCLASS_REWRITE, /* pg_rewrite */
OCLASS_TRIGGER, /* pg_trigger */
OCLASS_SCHEMA, /* pg_namespace */
OCLASS_TSPARSER, /* pg_ts_parser */
OCLASS_TSDICT, /* pg_ts_dict */
OCLASS_TSTEMPLATE, /* pg_ts_template */
OCLASS_TSCONFIG, /* pg_ts_config */
OCLASS_ROLE, /* pg_authid */
OCLASS_DATABASE, /* pg_database */
OCLASS_TBLSPACE, /* pg_tablespace */
OCLASS_FDW, /* pg_foreign_data_wrapper */
OCLASS_FOREIGN_SERVER, /* pg_foreign_server */
OCLASS_USER_MAPPING, /* pg_user_mapping */
OCLASS_DEFACL, /* pg_default_acl */
OCLASS_EXTENSION, /* pg_extension */
MAX_OCLASS /* MUST BE LAST */
} ObjectClass;
/* in dependency.c */
extern void performDeletion(const ObjectAddress *object,
DropBehavior behavior);
extern void performMultipleDeletions(const ObjectAddresses *objects,
DropBehavior behavior);
extern void deleteWhatDependsOn(const ObjectAddress *object,
bool showNotices);
extern void recordDependencyOnExpr(const ObjectAddress *depender,
Node *expr, List *rtable,
DependencyType behavior);
extern void recordDependencyOnSingleRelExpr(const ObjectAddress *depender,
Node *expr, Oid relId,
DependencyType behavior,
DependencyType self_behavior);
extern ObjectClass getObjectClass(const ObjectAddress *object);
extern char *getObjectDescription(const ObjectAddress *object);
extern char *getObjectDescriptionOids(Oid classid, Oid objid);
extern ObjectAddresses *new_object_addresses(void);
extern void add_exact_object_address(const ObjectAddress *object,
ObjectAddresses *addrs);
extern bool object_address_present(const ObjectAddress *object,
const ObjectAddresses *addrs);
extern void record_object_address_dependencies(const ObjectAddress *depender,
ObjectAddresses *referenced,
DependencyType behavior);
extern void free_object_addresses(ObjectAddresses *addrs);
/* in pg_depend.c */
extern void recordDependencyOn(const ObjectAddress *depender,
const ObjectAddress *referenced,
DependencyType behavior);
extern void recordMultipleDependencies(const ObjectAddress *depender,
const ObjectAddress *referenced,
int nreferenced,
DependencyType behavior);
extern void recordDependencyOnCurrentExtension(const ObjectAddress *object,
bool isReplace);
extern long deleteDependencyRecordsFor(Oid classId, Oid objectId,
bool skipExtensionDeps);
extern long deleteDependencyRecordsForClass(Oid classId, Oid objectId,
Oid refclassId, char deptype);
extern long changeDependencyFor(Oid classId, Oid objectId,
Oid refClassId, Oid oldRefObjectId,
Oid newRefObjectId);
extern Oid getExtensionOfObject(Oid classId, Oid objectId);
extern bool sequenceIsOwned(Oid seqId, Oid *tableId, int32 *colId);
extern void markSequenceUnowned(Oid seqId);
extern List *getOwnedSequences(Oid relid);
extern Oid get_constraint_index(Oid constraintId);
extern Oid get_index_constraint(Oid indexId);
/* in pg_shdepend.c */
extern void recordSharedDependencyOn(ObjectAddress *depender,
ObjectAddress *referenced,
SharedDependencyType deptype);
extern void deleteSharedDependencyRecordsFor(Oid classId, Oid objectId,
int32 objectSubId);
extern void recordDependencyOnOwner(Oid classId, Oid objectId, Oid owner);
extern void changeDependencyOnOwner(Oid classId, Oid objectId,
Oid newOwnerId);
extern void updateAclDependencies(Oid classId, Oid objectId, int32 objectSubId,
Oid ownerId,
int noldmembers, Oid *oldmembers,
int nnewmembers, Oid *newmembers);
extern bool checkSharedDependencies(Oid classId, Oid objectId,
char **detail_msg, char **detail_log_msg);
extern void shdepLockAndCheckObject(Oid classId, Oid objectId);
extern void copyTemplateDependencies(Oid templateDbId, Oid newDbId);
extern void dropDatabaseDependencies(Oid databaseId);
extern void shdepDropOwned(List *relids, DropBehavior behavior);
extern void shdepReassignOwned(List *relids, Oid newrole);
#endif /* DEPENDENCY_H */

View file

@ -0,0 +1,30 @@
#!/bin/sh
#
# duplicate_oids
#
# src/include/catalog/duplicate_oids
#
# finds manually-assigned oids that are duplicated in the system tables.
#
# run this script in src/include/catalog.
#
# note: we exclude BKI_BOOTSTRAP relations since they are expected to have
# matching DATA lines in pg_class.h and pg_type.h
cat pg_*.h toasting.h indexing.h | \
egrep -v -e '^CATALOG\(.*BKI_BOOTSTRAP' | \
sed -n -e 's/^DATA(insert *OID *= *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^CATALOG([^,]*, *\([0-9][0-9]*\).*BKI_ROWTYPE_OID(\([0-9][0-9]*\)).*$/\1,\2/p' \
-e 's/^CATALOG([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_INDEX([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_UNIQUE_INDEX([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_TOAST([^,]*, *\([0-9][0-9]*\), *\([0-9][0-9]*\).*$/\1,\2/p' | \
tr ',' '\n' | \
sort -n | \
uniq -d | \
grep '.'
# nonzero exit code if lines were produced
[ $? -eq 1 ]
exit

42
deps/libpq/include/catalog/genbki.h vendored Normal file
View file

@ -0,0 +1,42 @@
/*-------------------------------------------------------------------------
*
* genbki.h
* Required include file for all POSTGRES catalog header files
*
* genbki.h defines CATALOG(), DATA(), BKI_BOOTSTRAP and related macros
* so that the catalog header files can be read by the C compiler.
* (These same words are recognized by genbki.pl to build the BKI
* bootstrap file from these header files.)
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/genbki.h
*
*-------------------------------------------------------------------------
*/
#ifndef GENBKI_H
#define GENBKI_H
/* Introduces a catalog's structure definition */
#define CATALOG(name,oid) typedef struct CppConcat(FormData_,name)
/* Options that may appear after CATALOG (on the same line) */
#define BKI_BOOTSTRAP
#define BKI_SHARED_RELATION
#define BKI_WITHOUT_OIDS
#define BKI_ROWTYPE_OID(oid)
#define BKI_SCHEMA_MACRO
/* Declarations that provide the initial content of a catalog */
/* In C, these need to expand into some harmless, repeatable declaration */
#define DATA(x) extern int no_such_variable
#define DESCR(x) extern int no_such_variable
#define SHDESCR(x) extern int no_such_variable
/* PHONY type definitions for use in catalog structure definitions only */
typedef int aclitem;
typedef int pg_node_tree;
#endif /* GENBKI_H */

126
deps/libpq/include/catalog/heap.h vendored Normal file
View file

@ -0,0 +1,126 @@
/*-------------------------------------------------------------------------
*
* heap.h
* prototypes for functions in backend/catalog/heap.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/heap.h
*
*-------------------------------------------------------------------------
*/
#ifndef HEAP_H
#define HEAP_H
#include "parser/parse_node.h"
#include "catalog/indexing.h"
typedef struct RawColumnDefault
{
AttrNumber attnum; /* attribute to attach default to */
Node *raw_default; /* default value (untransformed parse tree) */
} RawColumnDefault;
typedef struct CookedConstraint
{
ConstrType contype; /* CONSTR_DEFAULT or CONSTR_CHECK */
char *name; /* name, or NULL if none */
AttrNumber attnum; /* which attr (only for DEFAULT) */
Node *expr; /* transformed default or check expr */
bool is_local; /* constraint has local (non-inherited) def */
int inhcount; /* number of times constraint is inherited */
} CookedConstraint;
extern Relation heap_create(const char *relname,
Oid relnamespace,
Oid reltablespace,
Oid relid,
TupleDesc tupDesc,
char relkind,
char relpersistence,
bool shared_relation,
bool mapped_relation,
bool allow_system_table_mods);
extern Oid heap_create_with_catalog(const char *relname,
Oid relnamespace,
Oid reltablespace,
Oid relid,
Oid reltypeid,
Oid reloftypeid,
Oid ownerid,
TupleDesc tupdesc,
List *cooked_constraints,
char relkind,
char relpersistence,
bool shared_relation,
bool mapped_relation,
bool oidislocal,
int oidinhcount,
OnCommitAction oncommit,
Datum reloptions,
bool use_user_acl,
bool allow_system_table_mods);
extern void heap_create_init_fork(Relation rel);
extern void heap_drop_with_catalog(Oid relid);
extern void heap_truncate(List *relids);
extern void heap_truncate_one_rel(Relation rel);
extern void heap_truncate_check_FKs(List *relations, bool tempTables);
extern List *heap_truncate_find_FKs(List *relationIds);
extern void InsertPgAttributeTuple(Relation pg_attribute_rel,
Form_pg_attribute new_attribute,
CatalogIndexState indstate);
extern void InsertPgClassTuple(Relation pg_class_desc,
Relation new_rel_desc,
Oid new_rel_oid,
Datum relacl,
Datum reloptions);
extern List *AddRelationNewConstraints(Relation rel,
List *newColDefaults,
List *newConstraints,
bool allow_merge,
bool is_local);
extern void StoreAttrDefault(Relation rel, AttrNumber attnum, Node *expr);
extern Node *cookDefault(ParseState *pstate,
Node *raw_default,
Oid atttypid,
int32 atttypmod,
char *attname);
extern void DeleteRelationTuple(Oid relid);
extern void DeleteAttributeTuples(Oid relid);
extern void RemoveAttributeById(Oid relid, AttrNumber attnum);
extern void RemoveAttrDefault(Oid relid, AttrNumber attnum,
DropBehavior behavior, bool complain);
extern void RemoveAttrDefaultById(Oid attrdefId);
extern void RemoveStatistics(Oid relid, AttrNumber attnum);
extern Form_pg_attribute SystemAttributeDefinition(AttrNumber attno,
bool relhasoids);
extern Form_pg_attribute SystemAttributeByName(const char *attname,
bool relhasoids);
extern void CheckAttributeNamesTypes(TupleDesc tupdesc, char relkind,
bool allow_system_table_mods);
extern void CheckAttributeType(const char *attname,
Oid atttypid, Oid attcollation,
List *containing_rowtypes,
bool allow_system_table_mods);
#endif /* HEAP_H */

102
deps/libpq/include/catalog/index.h vendored Normal file
View file

@ -0,0 +1,102 @@
/*-------------------------------------------------------------------------
*
* index.h
* prototypes for catalog/index.c.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/index.h
*
*-------------------------------------------------------------------------
*/
#ifndef INDEX_H
#define INDEX_H
#include "nodes/execnodes.h"
#define DEFAULT_INDEX_TYPE "btree"
/* Typedef for callback function for IndexBuildHeapScan */
typedef void (*IndexBuildCallback) (Relation index,
HeapTuple htup,
Datum *values,
bool *isnull,
bool tupleIsAlive,
void *state);
extern void index_check_primary_key(Relation heapRel,
IndexInfo *indexInfo,
bool is_alter_table);
extern Oid index_create(Relation heapRelation,
const char *indexRelationName,
Oid indexRelationId,
IndexInfo *indexInfo,
List *indexColNames,
Oid accessMethodObjectId,
Oid tableSpaceId,
Oid *collationObjectId,
Oid *classObjectId,
int16 *coloptions,
Datum reloptions,
bool isprimary,
bool isconstraint,
bool deferrable,
bool initdeferred,
bool allow_system_table_mods,
bool skip_build,
bool concurrent);
extern void index_constraint_create(Relation heapRelation,
Oid indexRelationId,
IndexInfo *indexInfo,
const char *constraintName,
char constraintType,
bool deferrable,
bool initdeferred,
bool mark_as_primary,
bool update_pgindex,
bool allow_system_table_mods);
extern void index_drop(Oid indexId);
extern IndexInfo *BuildIndexInfo(Relation index);
extern void FormIndexDatum(IndexInfo *indexInfo,
TupleTableSlot *slot,
EState *estate,
Datum *values,
bool *isnull);
extern void index_build(Relation heapRelation,
Relation indexRelation,
IndexInfo *indexInfo,
bool isprimary,
bool isreindex);
extern double IndexBuildHeapScan(Relation heapRelation,
Relation indexRelation,
IndexInfo *indexInfo,
bool allow_sync,
IndexBuildCallback callback,
void *callback_state);
extern void validate_index(Oid heapId, Oid indexId, Snapshot snapshot);
extern void reindex_index(Oid indexId, bool skip_constraint_checks);
/* Flag bits for reindex_relation(): */
#define REINDEX_REL_PROCESS_TOAST 0x01
#define REINDEX_REL_SUPPRESS_INDEX_USE 0x02
#define REINDEX_REL_CHECK_CONSTRAINTS 0x04
extern bool reindex_relation(Oid relid, int flags);
extern bool ReindexIsProcessingHeap(Oid heapOid);
extern bool ReindexIsProcessingIndex(Oid indexOid);
#endif /* INDEX_H */

306
deps/libpq/include/catalog/indexing.h vendored Normal file
View file

@ -0,0 +1,306 @@
/*-------------------------------------------------------------------------
*
* indexing.h
* This file provides some definitions to support indexing
* on system catalogs
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/indexing.h
*
*-------------------------------------------------------------------------
*/
#ifndef INDEXING_H
#define INDEXING_H
#include "access/htup.h"
#include "utils/relcache.h"
/*
* The state object used by CatalogOpenIndexes and friends is actually the
* same as the executor's ResultRelInfo, but we give it another type name
* to decouple callers from that fact.
*/
typedef struct ResultRelInfo *CatalogIndexState;
/*
* indexing.c prototypes
*/
extern CatalogIndexState CatalogOpenIndexes(Relation heapRel);
extern void CatalogCloseIndexes(CatalogIndexState indstate);
extern void CatalogIndexInsert(CatalogIndexState indstate,
HeapTuple heapTuple);
extern void CatalogUpdateIndexes(Relation heapRel, HeapTuple heapTuple);
/*
* These macros are just to keep the C compiler from spitting up on the
* upcoming commands for genbki.pl.
*/
#define DECLARE_INDEX(name,oid,decl) extern int no_such_variable
#define DECLARE_UNIQUE_INDEX(name,oid,decl) extern int no_such_variable
#define BUILD_INDICES
/*
* What follows are lines processed by genbki.pl to create the statements
* the bootstrap parser will turn into DefineIndex commands.
*
* The keyword is DECLARE_INDEX or DECLARE_UNIQUE_INDEX. The first two
* arguments are the index name and OID, the rest is much like a standard
* 'create index' SQL command.
*
* For each index, we also provide a #define for its OID. References to
* the index in the C code should always use these #defines, not the actual
* index name (much less the numeric OID).
*/
DECLARE_UNIQUE_INDEX(pg_aggregate_fnoid_index, 2650, on pg_aggregate using btree(aggfnoid oid_ops));
#define AggregateFnoidIndexId 2650
DECLARE_UNIQUE_INDEX(pg_am_name_index, 2651, on pg_am using btree(amname name_ops));
#define AmNameIndexId 2651
DECLARE_UNIQUE_INDEX(pg_am_oid_index, 2652, on pg_am using btree(oid oid_ops));
#define AmOidIndexId 2652
DECLARE_UNIQUE_INDEX(pg_amop_fam_strat_index, 2653, on pg_amop using btree(amopfamily oid_ops, amoplefttype oid_ops, amoprighttype oid_ops, amopstrategy int2_ops));
#define AccessMethodStrategyIndexId 2653
DECLARE_UNIQUE_INDEX(pg_amop_opr_fam_index, 2654, on pg_amop using btree(amopopr oid_ops, amoppurpose char_ops, amopfamily oid_ops));
#define AccessMethodOperatorIndexId 2654
DECLARE_UNIQUE_INDEX(pg_amop_oid_index, 2756, on pg_amop using btree(oid oid_ops));
#define AccessMethodOperatorOidIndexId 2756
DECLARE_UNIQUE_INDEX(pg_amproc_fam_proc_index, 2655, on pg_amproc using btree(amprocfamily oid_ops, amproclefttype oid_ops, amprocrighttype oid_ops, amprocnum int2_ops));
#define AccessMethodProcedureIndexId 2655
DECLARE_UNIQUE_INDEX(pg_amproc_oid_index, 2757, on pg_amproc using btree(oid oid_ops));
#define AccessMethodProcedureOidIndexId 2757
DECLARE_UNIQUE_INDEX(pg_attrdef_adrelid_adnum_index, 2656, on pg_attrdef using btree(adrelid oid_ops, adnum int2_ops));
#define AttrDefaultIndexId 2656
DECLARE_UNIQUE_INDEX(pg_attrdef_oid_index, 2657, on pg_attrdef using btree(oid oid_ops));
#define AttrDefaultOidIndexId 2657
DECLARE_UNIQUE_INDEX(pg_attribute_relid_attnam_index, 2658, on pg_attribute using btree(attrelid oid_ops, attname name_ops));
#define AttributeRelidNameIndexId 2658
DECLARE_UNIQUE_INDEX(pg_attribute_relid_attnum_index, 2659, on pg_attribute using btree(attrelid oid_ops, attnum int2_ops));
#define AttributeRelidNumIndexId 2659
DECLARE_UNIQUE_INDEX(pg_authid_rolname_index, 2676, on pg_authid using btree(rolname name_ops));
#define AuthIdRolnameIndexId 2676
DECLARE_UNIQUE_INDEX(pg_authid_oid_index, 2677, on pg_authid using btree(oid oid_ops));
#define AuthIdOidIndexId 2677
DECLARE_UNIQUE_INDEX(pg_auth_members_role_member_index, 2694, on pg_auth_members using btree(roleid oid_ops, member oid_ops));
#define AuthMemRoleMemIndexId 2694
DECLARE_UNIQUE_INDEX(pg_auth_members_member_role_index, 2695, on pg_auth_members using btree(member oid_ops, roleid oid_ops));
#define AuthMemMemRoleIndexId 2695
DECLARE_UNIQUE_INDEX(pg_cast_oid_index, 2660, on pg_cast using btree(oid oid_ops));
#define CastOidIndexId 2660
DECLARE_UNIQUE_INDEX(pg_cast_source_target_index, 2661, on pg_cast using btree(castsource oid_ops, casttarget oid_ops));
#define CastSourceTargetIndexId 2661
DECLARE_UNIQUE_INDEX(pg_class_oid_index, 2662, on pg_class using btree(oid oid_ops));
#define ClassOidIndexId 2662
DECLARE_UNIQUE_INDEX(pg_class_relname_nsp_index, 2663, on pg_class using btree(relname name_ops, relnamespace oid_ops));
#define ClassNameNspIndexId 2663
DECLARE_UNIQUE_INDEX(pg_collation_name_enc_nsp_index, 3164, on pg_collation using btree(collname name_ops, collencoding int4_ops, collnamespace oid_ops));
#define CollationNameEncNspIndexId 3164
DECLARE_UNIQUE_INDEX(pg_collation_oid_index, 3085, on pg_collation using btree(oid oid_ops));
#define CollationOidIndexId 3085
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_constraint_conname_nsp_index, 2664, on pg_constraint using btree(conname name_ops, connamespace oid_ops));
#define ConstraintNameNspIndexId 2664
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_constraint_conrelid_index, 2665, on pg_constraint using btree(conrelid oid_ops));
#define ConstraintRelidIndexId 2665
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_constraint_contypid_index, 2666, on pg_constraint using btree(contypid oid_ops));
#define ConstraintTypidIndexId 2666
DECLARE_UNIQUE_INDEX(pg_constraint_oid_index, 2667, on pg_constraint using btree(oid oid_ops));
#define ConstraintOidIndexId 2667
DECLARE_UNIQUE_INDEX(pg_conversion_default_index, 2668, on pg_conversion using btree(connamespace oid_ops, conforencoding int4_ops, contoencoding int4_ops, oid oid_ops));
#define ConversionDefaultIndexId 2668
DECLARE_UNIQUE_INDEX(pg_conversion_name_nsp_index, 2669, on pg_conversion using btree(conname name_ops, connamespace oid_ops));
#define ConversionNameNspIndexId 2669
DECLARE_UNIQUE_INDEX(pg_conversion_oid_index, 2670, on pg_conversion using btree(oid oid_ops));
#define ConversionOidIndexId 2670
DECLARE_UNIQUE_INDEX(pg_database_datname_index, 2671, on pg_database using btree(datname name_ops));
#define DatabaseNameIndexId 2671
DECLARE_UNIQUE_INDEX(pg_database_oid_index, 2672, on pg_database using btree(oid oid_ops));
#define DatabaseOidIndexId 2672
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_depend_depender_index, 2673, on pg_depend using btree(classid oid_ops, objid oid_ops, objsubid int4_ops));
#define DependDependerIndexId 2673
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_depend_reference_index, 2674, on pg_depend using btree(refclassid oid_ops, refobjid oid_ops, refobjsubid int4_ops));
#define DependReferenceIndexId 2674
DECLARE_UNIQUE_INDEX(pg_description_o_c_o_index, 2675, on pg_description using btree(objoid oid_ops, classoid oid_ops, objsubid int4_ops));
#define DescriptionObjIndexId 2675
DECLARE_UNIQUE_INDEX(pg_shdescription_o_c_index, 2397, on pg_shdescription using btree(objoid oid_ops, classoid oid_ops));
#define SharedDescriptionObjIndexId 2397
DECLARE_UNIQUE_INDEX(pg_enum_oid_index, 3502, on pg_enum using btree(oid oid_ops));
#define EnumOidIndexId 3502
DECLARE_UNIQUE_INDEX(pg_enum_typid_label_index, 3503, on pg_enum using btree(enumtypid oid_ops, enumlabel name_ops));
#define EnumTypIdLabelIndexId 3503
DECLARE_UNIQUE_INDEX(pg_enum_typid_sortorder_index, 3534, on pg_enum using btree(enumtypid oid_ops, enumsortorder float4_ops));
#define EnumTypIdSortOrderIndexId 3534
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_index_indrelid_index, 2678, on pg_index using btree(indrelid oid_ops));
#define IndexIndrelidIndexId 2678
DECLARE_UNIQUE_INDEX(pg_index_indexrelid_index, 2679, on pg_index using btree(indexrelid oid_ops));
#define IndexRelidIndexId 2679
DECLARE_UNIQUE_INDEX(pg_inherits_relid_seqno_index, 2680, on pg_inherits using btree(inhrelid oid_ops, inhseqno int4_ops));
#define InheritsRelidSeqnoIndexId 2680
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_inherits_parent_index, 2187, on pg_inherits using btree(inhparent oid_ops));
#define InheritsParentIndexId 2187
DECLARE_UNIQUE_INDEX(pg_language_name_index, 2681, on pg_language using btree(lanname name_ops));
#define LanguageNameIndexId 2681
DECLARE_UNIQUE_INDEX(pg_language_oid_index, 2682, on pg_language using btree(oid oid_ops));
#define LanguageOidIndexId 2682
DECLARE_UNIQUE_INDEX(pg_largeobject_loid_pn_index, 2683, on pg_largeobject using btree(loid oid_ops, pageno int4_ops));
#define LargeObjectLOidPNIndexId 2683
DECLARE_UNIQUE_INDEX(pg_largeobject_metadata_oid_index, 2996, on pg_largeobject_metadata using btree(oid oid_ops));
#define LargeObjectMetadataOidIndexId 2996
DECLARE_UNIQUE_INDEX(pg_namespace_nspname_index, 2684, on pg_namespace using btree(nspname name_ops));
#define NamespaceNameIndexId 2684
DECLARE_UNIQUE_INDEX(pg_namespace_oid_index, 2685, on pg_namespace using btree(oid oid_ops));
#define NamespaceOidIndexId 2685
DECLARE_UNIQUE_INDEX(pg_opclass_am_name_nsp_index, 2686, on pg_opclass using btree(opcmethod oid_ops, opcname name_ops, opcnamespace oid_ops));
#define OpclassAmNameNspIndexId 2686
DECLARE_UNIQUE_INDEX(pg_opclass_oid_index, 2687, on pg_opclass using btree(oid oid_ops));
#define OpclassOidIndexId 2687
DECLARE_UNIQUE_INDEX(pg_operator_oid_index, 2688, on pg_operator using btree(oid oid_ops));
#define OperatorOidIndexId 2688
DECLARE_UNIQUE_INDEX(pg_operator_oprname_l_r_n_index, 2689, on pg_operator using btree(oprname name_ops, oprleft oid_ops, oprright oid_ops, oprnamespace oid_ops));
#define OperatorNameNspIndexId 2689
DECLARE_UNIQUE_INDEX(pg_opfamily_am_name_nsp_index, 2754, on pg_opfamily using btree(opfmethod oid_ops, opfname name_ops, opfnamespace oid_ops));
#define OpfamilyAmNameNspIndexId 2754
DECLARE_UNIQUE_INDEX(pg_opfamily_oid_index, 2755, on pg_opfamily using btree(oid oid_ops));
#define OpfamilyOidIndexId 2755
DECLARE_UNIQUE_INDEX(pg_pltemplate_name_index, 1137, on pg_pltemplate using btree(tmplname name_ops));
#define PLTemplateNameIndexId 1137
DECLARE_UNIQUE_INDEX(pg_proc_oid_index, 2690, on pg_proc using btree(oid oid_ops));
#define ProcedureOidIndexId 2690
DECLARE_UNIQUE_INDEX(pg_proc_proname_args_nsp_index, 2691, on pg_proc using btree(proname name_ops, proargtypes oidvector_ops, pronamespace oid_ops));
#define ProcedureNameArgsNspIndexId 2691
DECLARE_UNIQUE_INDEX(pg_rewrite_oid_index, 2692, on pg_rewrite using btree(oid oid_ops));
#define RewriteOidIndexId 2692
DECLARE_UNIQUE_INDEX(pg_rewrite_rel_rulename_index, 2693, on pg_rewrite using btree(ev_class oid_ops, rulename name_ops));
#define RewriteRelRulenameIndexId 2693
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_shdepend_depender_index, 1232, on pg_shdepend using btree(dbid oid_ops, classid oid_ops, objid oid_ops, objsubid int4_ops));
#define SharedDependDependerIndexId 1232
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_shdepend_reference_index, 1233, on pg_shdepend using btree(refclassid oid_ops, refobjid oid_ops));
#define SharedDependReferenceIndexId 1233
DECLARE_UNIQUE_INDEX(pg_statistic_relid_att_inh_index, 2696, on pg_statistic using btree(starelid oid_ops, staattnum int2_ops, stainherit bool_ops));
#define StatisticRelidAttnumInhIndexId 2696
DECLARE_UNIQUE_INDEX(pg_tablespace_oid_index, 2697, on pg_tablespace using btree(oid oid_ops));
#define TablespaceOidIndexId 2697
DECLARE_UNIQUE_INDEX(pg_tablespace_spcname_index, 2698, on pg_tablespace using btree(spcname name_ops));
#define TablespaceNameIndexId 2698
/* This following index is not used for a cache and is not unique */
DECLARE_INDEX(pg_trigger_tgconstraint_index, 2699, on pg_trigger using btree(tgconstraint oid_ops));
#define TriggerConstraintIndexId 2699
DECLARE_UNIQUE_INDEX(pg_trigger_tgrelid_tgname_index, 2701, on pg_trigger using btree(tgrelid oid_ops, tgname name_ops));
#define TriggerRelidNameIndexId 2701
DECLARE_UNIQUE_INDEX(pg_trigger_oid_index, 2702, on pg_trigger using btree(oid oid_ops));
#define TriggerOidIndexId 2702
DECLARE_UNIQUE_INDEX(pg_ts_config_cfgname_index, 3608, on pg_ts_config using btree(cfgname name_ops, cfgnamespace oid_ops));
#define TSConfigNameNspIndexId 3608
DECLARE_UNIQUE_INDEX(pg_ts_config_oid_index, 3712, on pg_ts_config using btree(oid oid_ops));
#define TSConfigOidIndexId 3712
DECLARE_UNIQUE_INDEX(pg_ts_config_map_index, 3609, on pg_ts_config_map using btree(mapcfg oid_ops, maptokentype int4_ops, mapseqno int4_ops));
#define TSConfigMapIndexId 3609
DECLARE_UNIQUE_INDEX(pg_ts_dict_dictname_index, 3604, on pg_ts_dict using btree(dictname name_ops, dictnamespace oid_ops));
#define TSDictionaryNameNspIndexId 3604
DECLARE_UNIQUE_INDEX(pg_ts_dict_oid_index, 3605, on pg_ts_dict using btree(oid oid_ops));
#define TSDictionaryOidIndexId 3605
DECLARE_UNIQUE_INDEX(pg_ts_parser_prsname_index, 3606, on pg_ts_parser using btree(prsname name_ops, prsnamespace oid_ops));
#define TSParserNameNspIndexId 3606
DECLARE_UNIQUE_INDEX(pg_ts_parser_oid_index, 3607, on pg_ts_parser using btree(oid oid_ops));
#define TSParserOidIndexId 3607
DECLARE_UNIQUE_INDEX(pg_ts_template_tmplname_index, 3766, on pg_ts_template using btree(tmplname name_ops, tmplnamespace oid_ops));
#define TSTemplateNameNspIndexId 3766
DECLARE_UNIQUE_INDEX(pg_ts_template_oid_index, 3767, on pg_ts_template using btree(oid oid_ops));
#define TSTemplateOidIndexId 3767
DECLARE_UNIQUE_INDEX(pg_type_oid_index, 2703, on pg_type using btree(oid oid_ops));
#define TypeOidIndexId 2703
DECLARE_UNIQUE_INDEX(pg_type_typname_nsp_index, 2704, on pg_type using btree(typname name_ops, typnamespace oid_ops));
#define TypeNameNspIndexId 2704
DECLARE_UNIQUE_INDEX(pg_foreign_data_wrapper_oid_index, 112, on pg_foreign_data_wrapper using btree(oid oid_ops));
#define ForeignDataWrapperOidIndexId 112
DECLARE_UNIQUE_INDEX(pg_foreign_data_wrapper_name_index, 548, on pg_foreign_data_wrapper using btree(fdwname name_ops));
#define ForeignDataWrapperNameIndexId 548
DECLARE_UNIQUE_INDEX(pg_foreign_server_oid_index, 113, on pg_foreign_server using btree(oid oid_ops));
#define ForeignServerOidIndexId 113
DECLARE_UNIQUE_INDEX(pg_foreign_server_name_index, 549, on pg_foreign_server using btree(srvname name_ops));
#define ForeignServerNameIndexId 549
DECLARE_UNIQUE_INDEX(pg_user_mapping_oid_index, 174, on pg_user_mapping using btree(oid oid_ops));
#define UserMappingOidIndexId 174
DECLARE_UNIQUE_INDEX(pg_user_mapping_user_server_index, 175, on pg_user_mapping using btree(umuser oid_ops, umserver oid_ops));
#define UserMappingUserServerIndexId 175
DECLARE_UNIQUE_INDEX(pg_foreign_table_relid_index, 3119, on pg_foreign_table using btree(ftrelid oid_ops));
#define ForeignTableRelidIndexId 3119
DECLARE_UNIQUE_INDEX(pg_default_acl_role_nsp_obj_index, 827, on pg_default_acl using btree(defaclrole oid_ops, defaclnamespace oid_ops, defaclobjtype char_ops));
#define DefaultAclRoleNspObjIndexId 827
DECLARE_UNIQUE_INDEX(pg_default_acl_oid_index, 828, on pg_default_acl using btree(oid oid_ops));
#define DefaultAclOidIndexId 828
DECLARE_UNIQUE_INDEX(pg_db_role_setting_databaseid_rol_index, 2965, on pg_db_role_setting using btree(setdatabase oid_ops, setrole oid_ops));
#define DbRoleSettingDatidRolidIndexId 2965
DECLARE_UNIQUE_INDEX(pg_seclabel_object_index, 3597, on pg_seclabel using btree(objoid oid_ops, classoid oid_ops, objsubid int4_ops, provider text_ops));
#define SecLabelObjectIndexId 3597
DECLARE_UNIQUE_INDEX(pg_extension_oid_index, 3080, on pg_extension using btree(oid oid_ops));
#define ExtensionOidIndexId 3080
DECLARE_UNIQUE_INDEX(pg_extension_name_index, 3081, on pg_extension using btree(extname name_ops));
#define ExtensionNameIndexId 3081
/* last step of initialization script: build the indexes declared above */
BUILD_INDICES
#endif /* INDEXING_H */

138
deps/libpq/include/catalog/namespace.h vendored Normal file
View file

@ -0,0 +1,138 @@
/*-------------------------------------------------------------------------
*
* namespace.h
* prototypes for functions in backend/catalog/namespace.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/namespace.h
*
*-------------------------------------------------------------------------
*/
#ifndef NAMESPACE_H
#define NAMESPACE_H
#include "nodes/primnodes.h"
/*
* This structure holds a list of possible functions or operators
* found by namespace lookup. Each function/operator is identified
* by OID and by argument types; the list must be pruned by type
* resolution rules that are embodied in the parser, not here.
* See FuncnameGetCandidates's comments for more info.
*/
typedef struct _FuncCandidateList
{
struct _FuncCandidateList *next;
int pathpos; /* for internal use of namespace lookup */
Oid oid; /* the function or operator's OID */
int nargs; /* number of arg types returned */
int nvargs; /* number of args to become variadic array */
int ndargs; /* number of defaulted args */
int *argnumbers; /* args' positional indexes, if named call */
Oid args[1]; /* arg types --- VARIABLE LENGTH ARRAY */
} *FuncCandidateList; /* VARIABLE LENGTH STRUCT */
/*
* Structure for xxxOverrideSearchPath functions
*/
typedef struct OverrideSearchPath
{
List *schemas; /* OIDs of explicitly named schemas */
bool addCatalog; /* implicitly prepend pg_catalog? */
bool addTemp; /* implicitly prepend temp schema? */
} OverrideSearchPath;
extern Oid RangeVarGetRelid(const RangeVar *relation, bool failOK);
extern Oid RangeVarGetCreationNamespace(const RangeVar *newRelation);
extern Oid RangeVarGetAndCheckCreationNamespace(const RangeVar *newRelation);
extern void RangeVarAdjustRelationPersistence(RangeVar *newRelation, Oid nspid);
extern Oid RelnameGetRelid(const char *relname);
extern bool RelationIsVisible(Oid relid);
extern Oid TypenameGetTypid(const char *typname);
extern bool TypeIsVisible(Oid typid);
extern FuncCandidateList FuncnameGetCandidates(List *names,
int nargs, List *argnames,
bool expand_variadic,
bool expand_defaults);
extern bool FunctionIsVisible(Oid funcid);
extern Oid OpernameGetOprid(List *names, Oid oprleft, Oid oprright);
extern FuncCandidateList OpernameGetCandidates(List *names, char oprkind);
extern bool OperatorIsVisible(Oid oprid);
extern Oid OpclassnameGetOpcid(Oid amid, const char *opcname);
extern bool OpclassIsVisible(Oid opcid);
extern Oid OpfamilynameGetOpfid(Oid amid, const char *opfname);
extern bool OpfamilyIsVisible(Oid opfid);
extern Oid CollationGetCollid(const char *collname);
extern bool CollationIsVisible(Oid collid);
extern Oid ConversionGetConid(const char *conname);
extern bool ConversionIsVisible(Oid conid);
extern Oid get_ts_parser_oid(List *names, bool missing_ok);
extern bool TSParserIsVisible(Oid prsId);
extern Oid get_ts_dict_oid(List *names, bool missing_ok);
extern bool TSDictionaryIsVisible(Oid dictId);
extern Oid get_ts_template_oid(List *names, bool missing_ok);
extern bool TSTemplateIsVisible(Oid tmplId);
extern Oid get_ts_config_oid(List *names, bool missing_ok);
extern bool TSConfigIsVisible(Oid cfgid);
extern void DeconstructQualifiedName(List *names,
char **nspname_p,
char **objname_p);
extern Oid LookupNamespaceNoError(const char *nspname);
extern Oid LookupExplicitNamespace(const char *nspname);
extern Oid get_namespace_oid(const char *nspname, bool missing_ok);
extern Oid LookupCreationNamespace(const char *nspname);
extern void CheckSetNamespace(Oid oldNspOid, Oid nspOid, Oid classid,
Oid objid);
extern Oid QualifiedNameGetCreationNamespace(List *names, char **objname_p);
extern RangeVar *makeRangeVarFromNameList(List *names);
extern char *NameListToString(List *names);
extern char *NameListToQuotedString(List *names);
extern bool isTempNamespace(Oid namespaceId);
extern bool isTempToastNamespace(Oid namespaceId);
extern bool isTempOrToastNamespace(Oid namespaceId);
extern bool isAnyTempNamespace(Oid namespaceId);
extern bool isOtherTempNamespace(Oid namespaceId);
extern int GetTempNamespaceBackendId(Oid namespaceId);
extern Oid GetTempToastNamespace(void);
extern void ResetTempTableNamespace(void);
extern OverrideSearchPath *GetOverrideSearchPath(MemoryContext context);
extern void PushOverrideSearchPath(OverrideSearchPath *newpath);
extern void PopOverrideSearchPath(void);
extern Oid get_collation_oid(List *collname, bool missing_ok);
extern Oid get_conversion_oid(List *conname, bool missing_ok);
extern Oid FindDefaultConversionProc(int4 for_encoding, int4 to_encoding);
/* initialization & transaction cleanup code */
extern void InitializeSearchPath(void);
extern void AtEOXact_Namespace(bool isCommit);
extern void AtEOSubXact_Namespace(bool isCommit, SubTransactionId mySubid,
SubTransactionId parentSubid);
/* stuff for search_path GUC variable */
extern char *namespace_search_path;
extern List *fetch_search_path(bool includeImplicit);
extern int fetch_search_path_array(Oid *sarray, int sarray_len);
#endif /* NAMESPACE_H */

View file

@ -0,0 +1,46 @@
/*
* objectaccess.h
*
* Object access hooks.
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*/
#ifndef OBJECTACCESS_H
#define OBJECTACCESS_H
/*
* Object access hooks are intended to be called just before or just after
* performing certain actions on a SQL object. This is intended as
* infrastructure for security or logging pluggins.
*
* OAT_POST_CREATE should be invoked just after the the object is created.
* Typically, this is done after inserting the primary catalog records and
* associated dependencies.
*
* Other types may be added in the future.
*/
typedef enum ObjectAccessType
{
OAT_POST_CREATE,
} ObjectAccessType;
/*
* Hook, and a macro to invoke it.
*/
typedef void (*object_access_hook_type) (ObjectAccessType access,
Oid classId,
Oid objectId,
int subId);
extern PGDLLIMPORT object_access_hook_type object_access_hook;
#define InvokeObjectAccessHook(access,classId,objectId,subId) \
do { \
if (object_access_hook) \
(*object_access_hook)((access),(classId),(objectId),(subId)); \
} while(0)
#endif /* OBJECTACCESS_H */

View file

@ -0,0 +1,37 @@
/*-------------------------------------------------------------------------
*
* objectaddress.h
* functions for working with object addresses
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/objectaddress.h
*
*-------------------------------------------------------------------------
*/
#ifndef OBJECTADDRESS_H
#define OBJECTADDRESS_H
#include "nodes/parsenodes.h"
#include "storage/lock.h"
#include "utils/rel.h"
/*
* An ObjectAddress represents a database object of any type.
*/
typedef struct ObjectAddress
{
Oid classId; /* Class Id from pg_class */
Oid objectId; /* OID of the object */
int32 objectSubId; /* Subitem within object (eg column), or 0 */
} ObjectAddress;
extern ObjectAddress get_object_address(ObjectType objtype, List *objname,
List *objargs, Relation *relp, LOCKMODE lockmode);
extern void check_object_ownership(Oid roleid,
ObjectType objtype, ObjectAddress address,
List *objname, List *objargs, Relation relation);
#endif /* PARSE_OBJECT_H */

View file

@ -0,0 +1,242 @@
/*-------------------------------------------------------------------------
*
* pg_aggregate.h
* definition of the system "aggregate" relation (pg_aggregate)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_aggregate.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AGGREGATE_H
#define PG_AGGREGATE_H
#include "catalog/genbki.h"
#include "nodes/pg_list.h"
/* ----------------------------------------------------------------
* pg_aggregate definition.
*
* cpp turns this into typedef struct FormData_pg_aggregate
*
* aggfnoid pg_proc OID of the aggregate itself
* aggtransfn transition function
* aggfinalfn final function (0 if none)
* aggsortop associated sort operator (0 if none)
* aggtranstype type of aggregate's transition (state) data
* agginitval initial value for transition state (can be NULL)
* ----------------------------------------------------------------
*/
#define AggregateRelationId 2600
CATALOG(pg_aggregate,2600) BKI_WITHOUT_OIDS
{
regproc aggfnoid;
regproc aggtransfn;
regproc aggfinalfn;
Oid aggsortop;
Oid aggtranstype;
text agginitval; /* VARIABLE LENGTH FIELD */
} FormData_pg_aggregate;
/* ----------------
* Form_pg_aggregate corresponds to a pointer to a tuple with
* the format of pg_aggregate relation.
* ----------------
*/
typedef FormData_pg_aggregate *Form_pg_aggregate;
/* ----------------
* compiler constants for pg_aggregate
* ----------------
*/
#define Natts_pg_aggregate 6
#define Anum_pg_aggregate_aggfnoid 1
#define Anum_pg_aggregate_aggtransfn 2
#define Anum_pg_aggregate_aggfinalfn 3
#define Anum_pg_aggregate_aggsortop 4
#define Anum_pg_aggregate_aggtranstype 5
#define Anum_pg_aggregate_agginitval 6
/* ----------------
* initial contents of pg_aggregate
* ---------------
*/
/* avg */
DATA(insert ( 2100 int8_avg_accum numeric_avg 0 1231 "{0,0}" ));
DATA(insert ( 2101 int4_avg_accum int8_avg 0 1016 "{0,0}" ));
DATA(insert ( 2102 int2_avg_accum int8_avg 0 1016 "{0,0}" ));
DATA(insert ( 2103 numeric_avg_accum numeric_avg 0 1231 "{0,0}" ));
DATA(insert ( 2104 float4_accum float8_avg 0 1022 "{0,0,0}" ));
DATA(insert ( 2105 float8_accum float8_avg 0 1022 "{0,0,0}" ));
DATA(insert ( 2106 interval_accum interval_avg 0 1187 "{0 second,0 second}" ));
/* sum */
DATA(insert ( 2107 int8_sum - 0 1700 _null_ ));
DATA(insert ( 2108 int4_sum - 0 20 _null_ ));
DATA(insert ( 2109 int2_sum - 0 20 _null_ ));
DATA(insert ( 2110 float4pl - 0 700 _null_ ));
DATA(insert ( 2111 float8pl - 0 701 _null_ ));
DATA(insert ( 2112 cash_pl - 0 790 _null_ ));
DATA(insert ( 2113 interval_pl - 0 1186 _null_ ));
DATA(insert ( 2114 numeric_add - 0 1700 _null_ ));
/* max */
DATA(insert ( 2115 int8larger - 413 20 _null_ ));
DATA(insert ( 2116 int4larger - 521 23 _null_ ));
DATA(insert ( 2117 int2larger - 520 21 _null_ ));
DATA(insert ( 2118 oidlarger - 610 26 _null_ ));
DATA(insert ( 2119 float4larger - 623 700 _null_ ));
DATA(insert ( 2120 float8larger - 674 701 _null_ ));
DATA(insert ( 2121 int4larger - 563 702 _null_ ));
DATA(insert ( 2122 date_larger - 1097 1082 _null_ ));
DATA(insert ( 2123 time_larger - 1112 1083 _null_ ));
DATA(insert ( 2124 timetz_larger - 1554 1266 _null_ ));
DATA(insert ( 2125 cashlarger - 903 790 _null_ ));
DATA(insert ( 2126 timestamp_larger - 2064 1114 _null_ ));
DATA(insert ( 2127 timestamptz_larger - 1324 1184 _null_ ));
DATA(insert ( 2128 interval_larger - 1334 1186 _null_ ));
DATA(insert ( 2129 text_larger - 666 25 _null_ ));
DATA(insert ( 2130 numeric_larger - 1756 1700 _null_ ));
DATA(insert ( 2050 array_larger - 1073 2277 _null_ ));
DATA(insert ( 2244 bpchar_larger - 1060 1042 _null_ ));
DATA(insert ( 2797 tidlarger - 2800 27 _null_ ));
DATA(insert ( 3526 enum_larger - 3519 3500 _null_ ));
/* min */
DATA(insert ( 2131 int8smaller - 412 20 _null_ ));
DATA(insert ( 2132 int4smaller - 97 23 _null_ ));
DATA(insert ( 2133 int2smaller - 95 21 _null_ ));
DATA(insert ( 2134 oidsmaller - 609 26 _null_ ));
DATA(insert ( 2135 float4smaller - 622 700 _null_ ));
DATA(insert ( 2136 float8smaller - 672 701 _null_ ));
DATA(insert ( 2137 int4smaller - 562 702 _null_ ));
DATA(insert ( 2138 date_smaller - 1095 1082 _null_ ));
DATA(insert ( 2139 time_smaller - 1110 1083 _null_ ));
DATA(insert ( 2140 timetz_smaller - 1552 1266 _null_ ));
DATA(insert ( 2141 cashsmaller - 902 790 _null_ ));
DATA(insert ( 2142 timestamp_smaller - 2062 1114 _null_ ));
DATA(insert ( 2143 timestamptz_smaller - 1322 1184 _null_ ));
DATA(insert ( 2144 interval_smaller - 1332 1186 _null_ ));
DATA(insert ( 2145 text_smaller - 664 25 _null_ ));
DATA(insert ( 2146 numeric_smaller - 1754 1700 _null_ ));
DATA(insert ( 2051 array_smaller - 1072 2277 _null_ ));
DATA(insert ( 2245 bpchar_smaller - 1058 1042 _null_ ));
DATA(insert ( 2798 tidsmaller - 2799 27 _null_ ));
DATA(insert ( 3527 enum_smaller - 3518 3500 _null_ ));
/* count */
DATA(insert ( 2147 int8inc_any - 0 20 "0" ));
DATA(insert ( 2803 int8inc - 0 20 "0" ));
/* var_pop */
DATA(insert ( 2718 int8_accum numeric_var_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2719 int4_accum numeric_var_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2720 int2_accum numeric_var_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2721 float4_accum float8_var_pop 0 1022 "{0,0,0}" ));
DATA(insert ( 2722 float8_accum float8_var_pop 0 1022 "{0,0,0}" ));
DATA(insert ( 2723 numeric_accum numeric_var_pop 0 1231 "{0,0,0}" ));
/* var_samp */
DATA(insert ( 2641 int8_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2642 int4_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2643 int2_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2644 float4_accum float8_var_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2645 float8_accum float8_var_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2646 numeric_accum numeric_var_samp 0 1231 "{0,0,0}" ));
/* variance: historical Postgres syntax for var_samp */
DATA(insert ( 2148 int8_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2149 int4_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2150 int2_accum numeric_var_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2151 float4_accum float8_var_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2152 float8_accum float8_var_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2153 numeric_accum numeric_var_samp 0 1231 "{0,0,0}" ));
/* stddev_pop */
DATA(insert ( 2724 int8_accum numeric_stddev_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2725 int4_accum numeric_stddev_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2726 int2_accum numeric_stddev_pop 0 1231 "{0,0,0}" ));
DATA(insert ( 2727 float4_accum float8_stddev_pop 0 1022 "{0,0,0}" ));
DATA(insert ( 2728 float8_accum float8_stddev_pop 0 1022 "{0,0,0}" ));
DATA(insert ( 2729 numeric_accum numeric_stddev_pop 0 1231 "{0,0,0}" ));
/* stddev_samp */
DATA(insert ( 2712 int8_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2713 int4_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2714 int2_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2715 float4_accum float8_stddev_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2716 float8_accum float8_stddev_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2717 numeric_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
/* stddev: historical Postgres syntax for stddev_samp */
DATA(insert ( 2154 int8_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2155 int4_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2156 int2_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
DATA(insert ( 2157 float4_accum float8_stddev_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2158 float8_accum float8_stddev_samp 0 1022 "{0,0,0}" ));
DATA(insert ( 2159 numeric_accum numeric_stddev_samp 0 1231 "{0,0,0}" ));
/* SQL2003 binary regression aggregates */
DATA(insert ( 2818 int8inc_float8_float8 - 0 20 "0" ));
DATA(insert ( 2819 float8_regr_accum float8_regr_sxx 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2820 float8_regr_accum float8_regr_syy 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2821 float8_regr_accum float8_regr_sxy 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2822 float8_regr_accum float8_regr_avgx 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2823 float8_regr_accum float8_regr_avgy 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2824 float8_regr_accum float8_regr_r2 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2825 float8_regr_accum float8_regr_slope 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2826 float8_regr_accum float8_regr_intercept 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2827 float8_regr_accum float8_covar_pop 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2828 float8_regr_accum float8_covar_samp 0 1022 "{0,0,0,0,0,0}" ));
DATA(insert ( 2829 float8_regr_accum float8_corr 0 1022 "{0,0,0,0,0,0}" ));
/* boolean-and and boolean-or */
DATA(insert ( 2517 booland_statefunc - 0 16 _null_ ));
DATA(insert ( 2518 boolor_statefunc - 0 16 _null_ ));
DATA(insert ( 2519 booland_statefunc - 0 16 _null_ ));
/* bitwise integer */
DATA(insert ( 2236 int2and - 0 21 _null_ ));
DATA(insert ( 2237 int2or - 0 21 _null_ ));
DATA(insert ( 2238 int4and - 0 23 _null_ ));
DATA(insert ( 2239 int4or - 0 23 _null_ ));
DATA(insert ( 2240 int8and - 0 20 _null_ ));
DATA(insert ( 2241 int8or - 0 20 _null_ ));
DATA(insert ( 2242 bitand - 0 1560 _null_ ));
DATA(insert ( 2243 bitor - 0 1560 _null_ ));
/* xml */
DATA(insert ( 2901 xmlconcat2 - 0 142 _null_ ));
/* array */
DATA(insert ( 2335 array_agg_transfn array_agg_finalfn 0 2281 _null_ ));
/* text */
DATA(insert ( 3538 string_agg_transfn string_agg_finalfn 0 2281 _null_ ));
/*
* prototypes for functions in pg_aggregate.c
*/
extern void AggregateCreate(const char *aggName,
Oid aggNamespace,
Oid *aggArgTypes,
int numArgs,
List *aggtransfnName,
List *aggfinalfnName,
List *aggsortopName,
Oid aggTransType,
const char *agginitval);
#endif /* PG_AGGREGATE_H */

129
deps/libpq/include/catalog/pg_am.h vendored Normal file
View file

@ -0,0 +1,129 @@
/*-------------------------------------------------------------------------
*
* pg_am.h
* definition of the system "access method" relation (pg_am)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_am.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AM_H
#define PG_AM_H
#include "catalog/genbki.h"
/* ----------------
* pg_am definition. cpp turns this into
* typedef struct FormData_pg_am
* ----------------
*/
#define AccessMethodRelationId 2601
CATALOG(pg_am,2601)
{
NameData amname; /* access method name */
int2 amstrategies; /* total number of strategies (operators) by
* which we can traverse/search this AM. Zero
* if AM does not have a fixed set of strategy
* assignments. */
int2 amsupport; /* total number of support functions that this
* AM uses */
bool amcanorder; /* does AM support order by column value? */
bool amcanorderbyop; /* does AM support order by operator result? */
bool amcanbackward; /* does AM support backward scan? */
bool amcanunique; /* does AM support UNIQUE indexes? */
bool amcanmulticol; /* does AM support multi-column indexes? */
bool amoptionalkey; /* can query omit key for the first column? */
bool amsearchnulls; /* can AM search for NULL/NOT NULL entries? */
bool amstorage; /* can storage type differ from column type? */
bool amclusterable; /* does AM support cluster command? */
bool ampredlocks; /* does AM handle predicate locks? */
Oid amkeytype; /* type of data in index, or InvalidOid */
regproc aminsert; /* "insert this tuple" function */
regproc ambeginscan; /* "prepare for index scan" function */
regproc amgettuple; /* "next valid tuple" function, or 0 */
regproc amgetbitmap; /* "fetch all valid tuples" function, or 0 */
regproc amrescan; /* "(re)start index scan" function */
regproc amendscan; /* "end index scan" function */
regproc ammarkpos; /* "mark current scan position" function */
regproc amrestrpos; /* "restore marked scan position" function */
regproc ambuild; /* "build new index" function */
regproc ambuildempty; /* "build empty index" function */
regproc ambulkdelete; /* bulk-delete function */
regproc amvacuumcleanup; /* post-VACUUM cleanup function */
regproc amcostestimate; /* estimate cost of an indexscan */
regproc amoptions; /* parse AM-specific parameters */
} FormData_pg_am;
/* ----------------
* Form_pg_am corresponds to a pointer to a tuple with
* the format of pg_am relation.
* ----------------
*/
typedef FormData_pg_am *Form_pg_am;
/* ----------------
* compiler constants for pg_am
* ----------------
*/
#define Natts_pg_am 28
#define Anum_pg_am_amname 1
#define Anum_pg_am_amstrategies 2
#define Anum_pg_am_amsupport 3
#define Anum_pg_am_amcanorder 4
#define Anum_pg_am_amcanorderbyop 5
#define Anum_pg_am_amcanbackward 6
#define Anum_pg_am_amcanunique 7
#define Anum_pg_am_amcanmulticol 8
#define Anum_pg_am_amoptionalkey 9
#define Anum_pg_am_amsearchnulls 10
#define Anum_pg_am_amstorage 11
#define Anum_pg_am_amclusterable 12
#define Anum_pg_am_ampredlocks 13
#define Anum_pg_am_amkeytype 14
#define Anum_pg_am_aminsert 15
#define Anum_pg_am_ambeginscan 16
#define Anum_pg_am_amgettuple 17
#define Anum_pg_am_amgetbitmap 18
#define Anum_pg_am_amrescan 19
#define Anum_pg_am_amendscan 20
#define Anum_pg_am_ammarkpos 21
#define Anum_pg_am_amrestrpos 22
#define Anum_pg_am_ambuild 23
#define Anum_pg_am_ambuildempty 24
#define Anum_pg_am_ambulkdelete 25
#define Anum_pg_am_amvacuumcleanup 26
#define Anum_pg_am_amcostestimate 27
#define Anum_pg_am_amoptions 28
/* ----------------
* initial contents of pg_am
* ----------------
*/
DATA(insert OID = 403 ( btree 5 1 t f t t t t t f t t 0 btinsert btbeginscan btgettuple btgetbitmap btrescan btendscan btmarkpos btrestrpos btbuild btbuildempty btbulkdelete btvacuumcleanup btcostestimate btoptions ));
DESCR("b-tree index access method");
#define BTREE_AM_OID 403
DATA(insert OID = 405 ( hash 1 1 f f t f f f f f f f 23 hashinsert hashbeginscan hashgettuple hashgetbitmap hashrescan hashendscan hashmarkpos hashrestrpos hashbuild hashbuildempty hashbulkdelete hashvacuumcleanup hashcostestimate hashoptions ));
DESCR("hash index access method");
#define HASH_AM_OID 405
DATA(insert OID = 783 ( gist 0 8 f t f f t t t t t f 0 gistinsert gistbeginscan gistgettuple gistgetbitmap gistrescan gistendscan gistmarkpos gistrestrpos gistbuild gistbuildempty gistbulkdelete gistvacuumcleanup gistcostestimate gistoptions ));
DESCR("GiST index access method");
#define GIST_AM_OID 783
DATA(insert OID = 2742 ( gin 0 5 f f f f t t f t f f 0 gininsert ginbeginscan - gingetbitmap ginrescan ginendscan ginmarkpos ginrestrpos ginbuild ginbuildempty ginbulkdelete ginvacuumcleanup gincostestimate ginoptions ));
DESCR("GIN index access method");
#define GIN_AM_OID 2742
#endif /* PG_AM_H */

712
deps/libpq/include/catalog/pg_amop.h vendored Normal file
View file

@ -0,0 +1,712 @@
/*-------------------------------------------------------------------------
*
* pg_amop.h
* definition of the system "amop" relation (pg_amop)
* along with the relation's initial contents.
*
* The amop table identifies the operators associated with each index operator
* family and operator class (classes are subsets of families). An associated
* operator can be either a search operator or an ordering operator, as
* identified by amoppurpose.
*
* The primary key for this table is <amopfamily, amoplefttype, amoprighttype,
* amopstrategy>. amoplefttype and amoprighttype are just copies of the
* operator's oprleft/oprright, ie its declared input data types. The
* "default" operators for a particular opclass within the family are those
* with amoplefttype = amoprighttype = opclass's opcintype. An opfamily may
* also contain other operators, typically cross-data-type operators. All the
* operators within a family are supposed to be compatible, in a way that is
* defined by each individual index AM.
*
* We also keep a unique index on <amopopr, amoppurpose, amopfamily>, so that
* we can use a syscache to quickly answer questions of the form "is this
* operator in this opfamily, and if so what are its semantics with respect to
* the family?" This implies that the same operator cannot be listed for
* multiple strategy numbers within a single opfamily, with the exception that
* it's possible to list it for both search and ordering purposes (with
* different strategy numbers for the two purposes).
*
* amopmethod is a copy of the owning opfamily's opfmethod field. This is an
* intentional denormalization of the catalogs to buy lookup speed.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_amop.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AMOP_H
#define PG_AMOP_H
#include "catalog/genbki.h"
/* ----------------
* pg_amop definition. cpp turns this into
* typedef struct FormData_pg_amop
* ----------------
*/
#define AccessMethodOperatorRelationId 2602
CATALOG(pg_amop,2602)
{
Oid amopfamily; /* the index opfamily this entry is for */
Oid amoplefttype; /* operator's left input data type */
Oid amoprighttype; /* operator's right input data type */
int2 amopstrategy; /* operator strategy number */
char amoppurpose; /* is operator for 's'earch or 'o'rdering? */
Oid amopopr; /* the operator's pg_operator OID */
Oid amopmethod; /* the index access method this entry is for */
Oid amopsortfamily; /* ordering opfamily OID, or 0 if search op */
} FormData_pg_amop;
/* allowed values of amoppurpose: */
#define AMOP_SEARCH 's' /* operator is for search */
#define AMOP_ORDER 'o' /* operator is for ordering */
/* ----------------
* Form_pg_amop corresponds to a pointer to a tuple with
* the format of pg_amop relation.
* ----------------
*/
typedef FormData_pg_amop *Form_pg_amop;
/* ----------------
* compiler constants for pg_amop
* ----------------
*/
#define Natts_pg_amop 8
#define Anum_pg_amop_amopfamily 1
#define Anum_pg_amop_amoplefttype 2
#define Anum_pg_amop_amoprighttype 3
#define Anum_pg_amop_amopstrategy 4
#define Anum_pg_amop_amoppurpose 5
#define Anum_pg_amop_amopopr 6
#define Anum_pg_amop_amopmethod 7
#define Anum_pg_amop_amopsortfamily 8
/* ----------------
* initial contents of pg_amop
* ----------------
*/
/*
* btree integer_ops
*/
/* default operators int2 */
DATA(insert ( 1976 21 21 1 s 95 403 0 ));
DATA(insert ( 1976 21 21 2 s 522 403 0 ));
DATA(insert ( 1976 21 21 3 s 94 403 0 ));
DATA(insert ( 1976 21 21 4 s 524 403 0 ));
DATA(insert ( 1976 21 21 5 s 520 403 0 ));
/* crosstype operators int24 */
DATA(insert ( 1976 21 23 1 s 534 403 0 ));
DATA(insert ( 1976 21 23 2 s 540 403 0 ));
DATA(insert ( 1976 21 23 3 s 532 403 0 ));
DATA(insert ( 1976 21 23 4 s 542 403 0 ));
DATA(insert ( 1976 21 23 5 s 536 403 0 ));
/* crosstype operators int28 */
DATA(insert ( 1976 21 20 1 s 1864 403 0 ));
DATA(insert ( 1976 21 20 2 s 1866 403 0 ));
DATA(insert ( 1976 21 20 3 s 1862 403 0 ));
DATA(insert ( 1976 21 20 4 s 1867 403 0 ));
DATA(insert ( 1976 21 20 5 s 1865 403 0 ));
/* default operators int4 */
DATA(insert ( 1976 23 23 1 s 97 403 0 ));
DATA(insert ( 1976 23 23 2 s 523 403 0 ));
DATA(insert ( 1976 23 23 3 s 96 403 0 ));
DATA(insert ( 1976 23 23 4 s 525 403 0 ));
DATA(insert ( 1976 23 23 5 s 521 403 0 ));
/* crosstype operators int42 */
DATA(insert ( 1976 23 21 1 s 535 403 0 ));
DATA(insert ( 1976 23 21 2 s 541 403 0 ));
DATA(insert ( 1976 23 21 3 s 533 403 0 ));
DATA(insert ( 1976 23 21 4 s 543 403 0 ));
DATA(insert ( 1976 23 21 5 s 537 403 0 ));
/* crosstype operators int48 */
DATA(insert ( 1976 23 20 1 s 37 403 0 ));
DATA(insert ( 1976 23 20 2 s 80 403 0 ));
DATA(insert ( 1976 23 20 3 s 15 403 0 ));
DATA(insert ( 1976 23 20 4 s 82 403 0 ));
DATA(insert ( 1976 23 20 5 s 76 403 0 ));
/* default operators int8 */
DATA(insert ( 1976 20 20 1 s 412 403 0 ));
DATA(insert ( 1976 20 20 2 s 414 403 0 ));
DATA(insert ( 1976 20 20 3 s 410 403 0 ));
DATA(insert ( 1976 20 20 4 s 415 403 0 ));
DATA(insert ( 1976 20 20 5 s 413 403 0 ));
/* crosstype operators int82 */
DATA(insert ( 1976 20 21 1 s 1870 403 0 ));
DATA(insert ( 1976 20 21 2 s 1872 403 0 ));
DATA(insert ( 1976 20 21 3 s 1868 403 0 ));
DATA(insert ( 1976 20 21 4 s 1873 403 0 ));
DATA(insert ( 1976 20 21 5 s 1871 403 0 ));
/* crosstype operators int84 */
DATA(insert ( 1976 20 23 1 s 418 403 0 ));
DATA(insert ( 1976 20 23 2 s 420 403 0 ));
DATA(insert ( 1976 20 23 3 s 416 403 0 ));
DATA(insert ( 1976 20 23 4 s 430 403 0 ));
DATA(insert ( 1976 20 23 5 s 419 403 0 ));
/*
* btree oid_ops
*/
DATA(insert ( 1989 26 26 1 s 609 403 0 ));
DATA(insert ( 1989 26 26 2 s 611 403 0 ));
DATA(insert ( 1989 26 26 3 s 607 403 0 ));
DATA(insert ( 1989 26 26 4 s 612 403 0 ));
DATA(insert ( 1989 26 26 5 s 610 403 0 ));
/*
* btree tid_ops
*/
DATA(insert ( 2789 27 27 1 s 2799 403 0 ));
DATA(insert ( 2789 27 27 2 s 2801 403 0 ));
DATA(insert ( 2789 27 27 3 s 387 403 0 ));
DATA(insert ( 2789 27 27 4 s 2802 403 0 ));
DATA(insert ( 2789 27 27 5 s 2800 403 0 ));
/*
* btree oidvector_ops
*/
DATA(insert ( 1991 30 30 1 s 645 403 0 ));
DATA(insert ( 1991 30 30 2 s 647 403 0 ));
DATA(insert ( 1991 30 30 3 s 649 403 0 ));
DATA(insert ( 1991 30 30 4 s 648 403 0 ));
DATA(insert ( 1991 30 30 5 s 646 403 0 ));
/*
* btree float_ops
*/
/* default operators float4 */
DATA(insert ( 1970 700 700 1 s 622 403 0 ));
DATA(insert ( 1970 700 700 2 s 624 403 0 ));
DATA(insert ( 1970 700 700 3 s 620 403 0 ));
DATA(insert ( 1970 700 700 4 s 625 403 0 ));
DATA(insert ( 1970 700 700 5 s 623 403 0 ));
/* crosstype operators float48 */
DATA(insert ( 1970 700 701 1 s 1122 403 0 ));
DATA(insert ( 1970 700 701 2 s 1124 403 0 ));
DATA(insert ( 1970 700 701 3 s 1120 403 0 ));
DATA(insert ( 1970 700 701 4 s 1125 403 0 ));
DATA(insert ( 1970 700 701 5 s 1123 403 0 ));
/* default operators float8 */
DATA(insert ( 1970 701 701 1 s 672 403 0 ));
DATA(insert ( 1970 701 701 2 s 673 403 0 ));
DATA(insert ( 1970 701 701 3 s 670 403 0 ));
DATA(insert ( 1970 701 701 4 s 675 403 0 ));
DATA(insert ( 1970 701 701 5 s 674 403 0 ));
/* crosstype operators float84 */
DATA(insert ( 1970 701 700 1 s 1132 403 0 ));
DATA(insert ( 1970 701 700 2 s 1134 403 0 ));
DATA(insert ( 1970 701 700 3 s 1130 403 0 ));
DATA(insert ( 1970 701 700 4 s 1135 403 0 ));
DATA(insert ( 1970 701 700 5 s 1133 403 0 ));
/*
* btree char_ops
*/
DATA(insert ( 429 18 18 1 s 631 403 0 ));
DATA(insert ( 429 18 18 2 s 632 403 0 ));
DATA(insert ( 429 18 18 3 s 92 403 0 ));
DATA(insert ( 429 18 18 4 s 634 403 0 ));
DATA(insert ( 429 18 18 5 s 633 403 0 ));
/*
* btree name_ops
*/
DATA(insert ( 1986 19 19 1 s 660 403 0 ));
DATA(insert ( 1986 19 19 2 s 661 403 0 ));
DATA(insert ( 1986 19 19 3 s 93 403 0 ));
DATA(insert ( 1986 19 19 4 s 663 403 0 ));
DATA(insert ( 1986 19 19 5 s 662 403 0 ));
/*
* btree text_ops
*/
DATA(insert ( 1994 25 25 1 s 664 403 0 ));
DATA(insert ( 1994 25 25 2 s 665 403 0 ));
DATA(insert ( 1994 25 25 3 s 98 403 0 ));
DATA(insert ( 1994 25 25 4 s 667 403 0 ));
DATA(insert ( 1994 25 25 5 s 666 403 0 ));
/*
* btree bpchar_ops
*/
DATA(insert ( 426 1042 1042 1 s 1058 403 0 ));
DATA(insert ( 426 1042 1042 2 s 1059 403 0 ));
DATA(insert ( 426 1042 1042 3 s 1054 403 0 ));
DATA(insert ( 426 1042 1042 4 s 1061 403 0 ));
DATA(insert ( 426 1042 1042 5 s 1060 403 0 ));
/*
* btree bytea_ops
*/
DATA(insert ( 428 17 17 1 s 1957 403 0 ));
DATA(insert ( 428 17 17 2 s 1958 403 0 ));
DATA(insert ( 428 17 17 3 s 1955 403 0 ));
DATA(insert ( 428 17 17 4 s 1960 403 0 ));
DATA(insert ( 428 17 17 5 s 1959 403 0 ));
/*
* btree abstime_ops
*/
DATA(insert ( 421 702 702 1 s 562 403 0 ));
DATA(insert ( 421 702 702 2 s 564 403 0 ));
DATA(insert ( 421 702 702 3 s 560 403 0 ));
DATA(insert ( 421 702 702 4 s 565 403 0 ));
DATA(insert ( 421 702 702 5 s 563 403 0 ));
/*
* btree datetime_ops
*/
/* default operators date */
DATA(insert ( 434 1082 1082 1 s 1095 403 0 ));
DATA(insert ( 434 1082 1082 2 s 1096 403 0 ));
DATA(insert ( 434 1082 1082 3 s 1093 403 0 ));
DATA(insert ( 434 1082 1082 4 s 1098 403 0 ));
DATA(insert ( 434 1082 1082 5 s 1097 403 0 ));
/* crosstype operators vs timestamp */
DATA(insert ( 434 1082 1114 1 s 2345 403 0 ));
DATA(insert ( 434 1082 1114 2 s 2346 403 0 ));
DATA(insert ( 434 1082 1114 3 s 2347 403 0 ));
DATA(insert ( 434 1082 1114 4 s 2348 403 0 ));
DATA(insert ( 434 1082 1114 5 s 2349 403 0 ));
/* crosstype operators vs timestamptz */
DATA(insert ( 434 1082 1184 1 s 2358 403 0 ));
DATA(insert ( 434 1082 1184 2 s 2359 403 0 ));
DATA(insert ( 434 1082 1184 3 s 2360 403 0 ));
DATA(insert ( 434 1082 1184 4 s 2361 403 0 ));
DATA(insert ( 434 1082 1184 5 s 2362 403 0 ));
/* default operators timestamp */
DATA(insert ( 434 1114 1114 1 s 2062 403 0 ));
DATA(insert ( 434 1114 1114 2 s 2063 403 0 ));
DATA(insert ( 434 1114 1114 3 s 2060 403 0 ));
DATA(insert ( 434 1114 1114 4 s 2065 403 0 ));
DATA(insert ( 434 1114 1114 5 s 2064 403 0 ));
/* crosstype operators vs date */
DATA(insert ( 434 1114 1082 1 s 2371 403 0 ));
DATA(insert ( 434 1114 1082 2 s 2372 403 0 ));
DATA(insert ( 434 1114 1082 3 s 2373 403 0 ));
DATA(insert ( 434 1114 1082 4 s 2374 403 0 ));
DATA(insert ( 434 1114 1082 5 s 2375 403 0 ));
/* crosstype operators vs timestamptz */
DATA(insert ( 434 1114 1184 1 s 2534 403 0 ));
DATA(insert ( 434 1114 1184 2 s 2535 403 0 ));
DATA(insert ( 434 1114 1184 3 s 2536 403 0 ));
DATA(insert ( 434 1114 1184 4 s 2537 403 0 ));
DATA(insert ( 434 1114 1184 5 s 2538 403 0 ));
/* default operators timestamptz */
DATA(insert ( 434 1184 1184 1 s 1322 403 0 ));
DATA(insert ( 434 1184 1184 2 s 1323 403 0 ));
DATA(insert ( 434 1184 1184 3 s 1320 403 0 ));
DATA(insert ( 434 1184 1184 4 s 1325 403 0 ));
DATA(insert ( 434 1184 1184 5 s 1324 403 0 ));
/* crosstype operators vs date */
DATA(insert ( 434 1184 1082 1 s 2384 403 0 ));
DATA(insert ( 434 1184 1082 2 s 2385 403 0 ));
DATA(insert ( 434 1184 1082 3 s 2386 403 0 ));
DATA(insert ( 434 1184 1082 4 s 2387 403 0 ));
DATA(insert ( 434 1184 1082 5 s 2388 403 0 ));
/* crosstype operators vs timestamp */
DATA(insert ( 434 1184 1114 1 s 2540 403 0 ));
DATA(insert ( 434 1184 1114 2 s 2541 403 0 ));
DATA(insert ( 434 1184 1114 3 s 2542 403 0 ));
DATA(insert ( 434 1184 1114 4 s 2543 403 0 ));
DATA(insert ( 434 1184 1114 5 s 2544 403 0 ));
/*
* btree time_ops
*/
DATA(insert ( 1996 1083 1083 1 s 1110 403 0 ));
DATA(insert ( 1996 1083 1083 2 s 1111 403 0 ));
DATA(insert ( 1996 1083 1083 3 s 1108 403 0 ));
DATA(insert ( 1996 1083 1083 4 s 1113 403 0 ));
DATA(insert ( 1996 1083 1083 5 s 1112 403 0 ));
/*
* btree timetz_ops
*/
DATA(insert ( 2000 1266 1266 1 s 1552 403 0 ));
DATA(insert ( 2000 1266 1266 2 s 1553 403 0 ));
DATA(insert ( 2000 1266 1266 3 s 1550 403 0 ));
DATA(insert ( 2000 1266 1266 4 s 1555 403 0 ));
DATA(insert ( 2000 1266 1266 5 s 1554 403 0 ));
/*
* btree interval_ops
*/
DATA(insert ( 1982 1186 1186 1 s 1332 403 0 ));
DATA(insert ( 1982 1186 1186 2 s 1333 403 0 ));
DATA(insert ( 1982 1186 1186 3 s 1330 403 0 ));
DATA(insert ( 1982 1186 1186 4 s 1335 403 0 ));
DATA(insert ( 1982 1186 1186 5 s 1334 403 0 ));
/*
* btree macaddr
*/
DATA(insert ( 1984 829 829 1 s 1222 403 0 ));
DATA(insert ( 1984 829 829 2 s 1223 403 0 ));
DATA(insert ( 1984 829 829 3 s 1220 403 0 ));
DATA(insert ( 1984 829 829 4 s 1225 403 0 ));
DATA(insert ( 1984 829 829 5 s 1224 403 0 ));
/*
* btree network
*/
DATA(insert ( 1974 869 869 1 s 1203 403 0 ));
DATA(insert ( 1974 869 869 2 s 1204 403 0 ));
DATA(insert ( 1974 869 869 3 s 1201 403 0 ));
DATA(insert ( 1974 869 869 4 s 1206 403 0 ));
DATA(insert ( 1974 869 869 5 s 1205 403 0 ));
/*
* btree numeric
*/
DATA(insert ( 1988 1700 1700 1 s 1754 403 0 ));
DATA(insert ( 1988 1700 1700 2 s 1755 403 0 ));
DATA(insert ( 1988 1700 1700 3 s 1752 403 0 ));
DATA(insert ( 1988 1700 1700 4 s 1757 403 0 ));
DATA(insert ( 1988 1700 1700 5 s 1756 403 0 ));
/*
* btree bool
*/
DATA(insert ( 424 16 16 1 s 58 403 0 ));
DATA(insert ( 424 16 16 2 s 1694 403 0 ));
DATA(insert ( 424 16 16 3 s 91 403 0 ));
DATA(insert ( 424 16 16 4 s 1695 403 0 ));
DATA(insert ( 424 16 16 5 s 59 403 0 ));
/*
* btree bit
*/
DATA(insert ( 423 1560 1560 1 s 1786 403 0 ));
DATA(insert ( 423 1560 1560 2 s 1788 403 0 ));
DATA(insert ( 423 1560 1560 3 s 1784 403 0 ));
DATA(insert ( 423 1560 1560 4 s 1789 403 0 ));
DATA(insert ( 423 1560 1560 5 s 1787 403 0 ));
/*
* btree varbit
*/
DATA(insert ( 2002 1562 1562 1 s 1806 403 0 ));
DATA(insert ( 2002 1562 1562 2 s 1808 403 0 ));
DATA(insert ( 2002 1562 1562 3 s 1804 403 0 ));
DATA(insert ( 2002 1562 1562 4 s 1809 403 0 ));
DATA(insert ( 2002 1562 1562 5 s 1807 403 0 ));
/*
* btree text pattern
*/
DATA(insert ( 2095 25 25 1 s 2314 403 0 ));
DATA(insert ( 2095 25 25 2 s 2315 403 0 ));
DATA(insert ( 2095 25 25 3 s 98 403 0 ));
DATA(insert ( 2095 25 25 4 s 2317 403 0 ));
DATA(insert ( 2095 25 25 5 s 2318 403 0 ));
/*
* btree bpchar pattern
*/
DATA(insert ( 2097 1042 1042 1 s 2326 403 0 ));
DATA(insert ( 2097 1042 1042 2 s 2327 403 0 ));
DATA(insert ( 2097 1042 1042 3 s 1054 403 0 ));
DATA(insert ( 2097 1042 1042 4 s 2329 403 0 ));
DATA(insert ( 2097 1042 1042 5 s 2330 403 0 ));
/*
* btree money_ops
*/
DATA(insert ( 2099 790 790 1 s 902 403 0 ));
DATA(insert ( 2099 790 790 2 s 904 403 0 ));
DATA(insert ( 2099 790 790 3 s 900 403 0 ));
DATA(insert ( 2099 790 790 4 s 905 403 0 ));
DATA(insert ( 2099 790 790 5 s 903 403 0 ));
/*
* btree reltime_ops
*/
DATA(insert ( 2233 703 703 1 s 568 403 0 ));
DATA(insert ( 2233 703 703 2 s 570 403 0 ));
DATA(insert ( 2233 703 703 3 s 566 403 0 ));
DATA(insert ( 2233 703 703 4 s 571 403 0 ));
DATA(insert ( 2233 703 703 5 s 569 403 0 ));
/*
* btree tinterval_ops
*/
DATA(insert ( 2234 704 704 1 s 813 403 0 ));
DATA(insert ( 2234 704 704 2 s 815 403 0 ));
DATA(insert ( 2234 704 704 3 s 811 403 0 ));
DATA(insert ( 2234 704 704 4 s 816 403 0 ));
DATA(insert ( 2234 704 704 5 s 814 403 0 ));
/*
* btree array_ops
*/
DATA(insert ( 397 2277 2277 1 s 1072 403 0 ));
DATA(insert ( 397 2277 2277 2 s 1074 403 0 ));
DATA(insert ( 397 2277 2277 3 s 1070 403 0 ));
DATA(insert ( 397 2277 2277 4 s 1075 403 0 ));
DATA(insert ( 397 2277 2277 5 s 1073 403 0 ));
/*
* btree record_ops
*/
DATA(insert ( 2994 2249 2249 1 s 2990 403 0 ));
DATA(insert ( 2994 2249 2249 2 s 2992 403 0 ));
DATA(insert ( 2994 2249 2249 3 s 2988 403 0 ));
DATA(insert ( 2994 2249 2249 4 s 2993 403 0 ));
DATA(insert ( 2994 2249 2249 5 s 2991 403 0 ));
/*
* btree uuid_ops
*/
DATA(insert ( 2968 2950 2950 1 s 2974 403 0 ));
DATA(insert ( 2968 2950 2950 2 s 2976 403 0 ));
DATA(insert ( 2968 2950 2950 3 s 2972 403 0 ));
DATA(insert ( 2968 2950 2950 4 s 2977 403 0 ));
DATA(insert ( 2968 2950 2950 5 s 2975 403 0 ));
/*
* hash index _ops
*/
/* bpchar_ops */
DATA(insert ( 427 1042 1042 1 s 1054 405 0 ));
/* char_ops */
DATA(insert ( 431 18 18 1 s 92 405 0 ));
/* date_ops */
DATA(insert ( 435 1082 1082 1 s 1093 405 0 ));
/* float_ops */
DATA(insert ( 1971 700 700 1 s 620 405 0 ));
DATA(insert ( 1971 701 701 1 s 670 405 0 ));
DATA(insert ( 1971 700 701 1 s 1120 405 0 ));
DATA(insert ( 1971 701 700 1 s 1130 405 0 ));
/* network_ops */
DATA(insert ( 1975 869 869 1 s 1201 405 0 ));
/* integer_ops */
DATA(insert ( 1977 21 21 1 s 94 405 0 ));
DATA(insert ( 1977 23 23 1 s 96 405 0 ));
DATA(insert ( 1977 20 20 1 s 410 405 0 ));
DATA(insert ( 1977 21 23 1 s 532 405 0 ));
DATA(insert ( 1977 21 20 1 s 1862 405 0 ));
DATA(insert ( 1977 23 21 1 s 533 405 0 ));
DATA(insert ( 1977 23 20 1 s 15 405 0 ));
DATA(insert ( 1977 20 21 1 s 1868 405 0 ));
DATA(insert ( 1977 20 23 1 s 416 405 0 ));
/* interval_ops */
DATA(insert ( 1983 1186 1186 1 s 1330 405 0 ));
/* macaddr_ops */
DATA(insert ( 1985 829 829 1 s 1220 405 0 ));
/* name_ops */
DATA(insert ( 1987 19 19 1 s 93 405 0 ));
/* oid_ops */
DATA(insert ( 1990 26 26 1 s 607 405 0 ));
/* oidvector_ops */
DATA(insert ( 1992 30 30 1 s 649 405 0 ));
/* text_ops */
DATA(insert ( 1995 25 25 1 s 98 405 0 ));
/* time_ops */
DATA(insert ( 1997 1083 1083 1 s 1108 405 0 ));
/* timestamptz_ops */
DATA(insert ( 1999 1184 1184 1 s 1320 405 0 ));
/* timetz_ops */
DATA(insert ( 2001 1266 1266 1 s 1550 405 0 ));
/* timestamp_ops */
DATA(insert ( 2040 1114 1114 1 s 2060 405 0 ));
/* bool_ops */
DATA(insert ( 2222 16 16 1 s 91 405 0 ));
/* bytea_ops */
DATA(insert ( 2223 17 17 1 s 1955 405 0 ));
/* int2vector_ops */
DATA(insert ( 2224 22 22 1 s 386 405 0 ));
/* xid_ops */
DATA(insert ( 2225 28 28 1 s 352 405 0 ));
/* cid_ops */
DATA(insert ( 2226 29 29 1 s 385 405 0 ));
/* abstime_ops */
DATA(insert ( 2227 702 702 1 s 560 405 0 ));
/* reltime_ops */
DATA(insert ( 2228 703 703 1 s 566 405 0 ));
/* text_pattern_ops */
DATA(insert ( 2229 25 25 1 s 98 405 0 ));
/* bpchar_pattern_ops */
DATA(insert ( 2231 1042 1042 1 s 1054 405 0 ));
/* aclitem_ops */
DATA(insert ( 2235 1033 1033 1 s 974 405 0 ));
/* uuid_ops */
DATA(insert ( 2969 2950 2950 1 s 2972 405 0 ));
/* numeric_ops */
DATA(insert ( 1998 1700 1700 1 s 1752 405 0 ));
/* array_ops */
DATA(insert ( 627 2277 2277 1 s 1070 405 0 ));
/*
* gist box_ops
*/
DATA(insert ( 2593 603 603 1 s 493 783 0 ));
DATA(insert ( 2593 603 603 2 s 494 783 0 ));
DATA(insert ( 2593 603 603 3 s 500 783 0 ));
DATA(insert ( 2593 603 603 4 s 495 783 0 ));
DATA(insert ( 2593 603 603 5 s 496 783 0 ));
DATA(insert ( 2593 603 603 6 s 499 783 0 ));
DATA(insert ( 2593 603 603 7 s 498 783 0 ));
DATA(insert ( 2593 603 603 8 s 497 783 0 ));
DATA(insert ( 2593 603 603 9 s 2571 783 0 ));
DATA(insert ( 2593 603 603 10 s 2570 783 0 ));
DATA(insert ( 2593 603 603 11 s 2573 783 0 ));
DATA(insert ( 2593 603 603 12 s 2572 783 0 ));
DATA(insert ( 2593 603 603 13 s 2863 783 0 ));
DATA(insert ( 2593 603 603 14 s 2862 783 0 ));
/*
* gist point_ops
*/
DATA(insert ( 1029 600 600 11 s 506 783 0 ));
DATA(insert ( 1029 600 600 1 s 507 783 0 ));
DATA(insert ( 1029 600 600 5 s 508 783 0 ));
DATA(insert ( 1029 600 600 10 s 509 783 0 ));
DATA(insert ( 1029 600 600 6 s 510 783 0 ));
DATA(insert ( 1029 600 600 15 o 517 783 1970 ));
DATA(insert ( 1029 603 600 27 s 433 783 0 ));
DATA(insert ( 1029 600 603 28 s 511 783 0 ));
DATA(insert ( 1029 604 600 47 s 757 783 0 ));
DATA(insert ( 1029 600 604 48 s 756 783 0 ));
DATA(insert ( 1029 718 600 67 s 759 783 0 ));
DATA(insert ( 1029 600 718 68 s 758 783 0 ));
/*
* gist poly_ops (supports polygons)
*/
DATA(insert ( 2594 604 604 1 s 485 783 0 ));
DATA(insert ( 2594 604 604 2 s 486 783 0 ));
DATA(insert ( 2594 604 604 3 s 492 783 0 ));
DATA(insert ( 2594 604 604 4 s 487 783 0 ));
DATA(insert ( 2594 604 604 5 s 488 783 0 ));
DATA(insert ( 2594 604 604 6 s 491 783 0 ));
DATA(insert ( 2594 604 604 7 s 490 783 0 ));
DATA(insert ( 2594 604 604 8 s 489 783 0 ));
DATA(insert ( 2594 604 604 9 s 2575 783 0 ));
DATA(insert ( 2594 604 604 10 s 2574 783 0 ));
DATA(insert ( 2594 604 604 11 s 2577 783 0 ));
DATA(insert ( 2594 604 604 12 s 2576 783 0 ));
DATA(insert ( 2594 604 604 13 s 2861 783 0 ));
DATA(insert ( 2594 604 604 14 s 2860 783 0 ));
/*
* gist circle_ops
*/
DATA(insert ( 2595 718 718 1 s 1506 783 0 ));
DATA(insert ( 2595 718 718 2 s 1507 783 0 ));
DATA(insert ( 2595 718 718 3 s 1513 783 0 ));
DATA(insert ( 2595 718 718 4 s 1508 783 0 ));
DATA(insert ( 2595 718 718 5 s 1509 783 0 ));
DATA(insert ( 2595 718 718 6 s 1512 783 0 ));
DATA(insert ( 2595 718 718 7 s 1511 783 0 ));
DATA(insert ( 2595 718 718 8 s 1510 783 0 ));
DATA(insert ( 2595 718 718 9 s 2589 783 0 ));
DATA(insert ( 2595 718 718 10 s 1515 783 0 ));
DATA(insert ( 2595 718 718 11 s 1514 783 0 ));
DATA(insert ( 2595 718 718 12 s 2590 783 0 ));
DATA(insert ( 2595 718 718 13 s 2865 783 0 ));
DATA(insert ( 2595 718 718 14 s 2864 783 0 ));
/*
* gin array_ops (these anyarray operators are used with all the opclasses
* of the family)
*/
DATA(insert ( 2745 2277 2277 1 s 2750 2742 0 ));
DATA(insert ( 2745 2277 2277 2 s 2751 2742 0 ));
DATA(insert ( 2745 2277 2277 3 s 2752 2742 0 ));
DATA(insert ( 2745 2277 2277 4 s 1070 2742 0 ));
/*
* btree enum_ops
*/
DATA(insert ( 3522 3500 3500 1 s 3518 403 0 ));
DATA(insert ( 3522 3500 3500 2 s 3520 403 0 ));
DATA(insert ( 3522 3500 3500 3 s 3516 403 0 ));
DATA(insert ( 3522 3500 3500 4 s 3521 403 0 ));
DATA(insert ( 3522 3500 3500 5 s 3519 403 0 ));
/*
* hash enum_ops
*/
DATA(insert ( 3523 3500 3500 1 s 3516 405 0 ));
/*
* btree tsvector_ops
*/
DATA(insert ( 3626 3614 3614 1 s 3627 403 0 ));
DATA(insert ( 3626 3614 3614 2 s 3628 403 0 ));
DATA(insert ( 3626 3614 3614 3 s 3629 403 0 ));
DATA(insert ( 3626 3614 3614 4 s 3631 403 0 ));
DATA(insert ( 3626 3614 3614 5 s 3632 403 0 ));
/*
* GiST tsvector_ops
*/
DATA(insert ( 3655 3614 3615 1 s 3636 783 0 ));
/*
* GIN tsvector_ops
*/
DATA(insert ( 3659 3614 3615 1 s 3636 2742 0 ));
DATA(insert ( 3659 3614 3615 2 s 3660 2742 0 ));
/*
* btree tsquery_ops
*/
DATA(insert ( 3683 3615 3615 1 s 3674 403 0 ));
DATA(insert ( 3683 3615 3615 2 s 3675 403 0 ));
DATA(insert ( 3683 3615 3615 3 s 3676 403 0 ));
DATA(insert ( 3683 3615 3615 4 s 3678 403 0 ));
DATA(insert ( 3683 3615 3615 5 s 3679 403 0 ));
/*
* GiST tsquery_ops
*/
DATA(insert ( 3702 3615 3615 7 s 3693 783 0 ));
DATA(insert ( 3702 3615 3615 8 s 3694 783 0 ));
#endif /* PG_AMOP_H */

340
deps/libpq/include/catalog/pg_amproc.h vendored Normal file
View file

@ -0,0 +1,340 @@
/*-------------------------------------------------------------------------
*
* pg_amproc.h
* definition of the system "amproc" relation (pg_amproc)
* along with the relation's initial contents.
*
* The amproc table identifies support procedures associated with index
* operator families and classes. These procedures can't be listed in pg_amop
* since they are not the implementation of any indexable operator.
*
* The primary key for this table is <amprocfamily, amproclefttype,
* amprocrighttype, amprocnum>. The "default" support functions for a
* particular opclass within the family are those with amproclefttype =
* amprocrighttype = opclass's opcintype. These are the ones loaded into the
* relcache for an index and typically used for internal index operations.
* Other support functions are typically used to handle cross-type indexable
* operators with oprleft/oprright matching the entry's amproclefttype and
* amprocrighttype. The exact behavior depends on the index AM, however, and
* some don't pay attention to non-default functions at all.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_amproc.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AMPROC_H
#define PG_AMPROC_H
#include "catalog/genbki.h"
/* ----------------
* pg_amproc definition. cpp turns this into
* typedef struct FormData_pg_amproc
* ----------------
*/
#define AccessMethodProcedureRelationId 2603
CATALOG(pg_amproc,2603)
{
Oid amprocfamily; /* the index opfamily this entry is for */
Oid amproclefttype; /* procedure's left input data type */
Oid amprocrighttype; /* procedure's right input data type */
int2 amprocnum; /* support procedure index */
regproc amproc; /* OID of the proc */
} FormData_pg_amproc;
/* ----------------
* Form_pg_amproc corresponds to a pointer to a tuple with
* the format of pg_amproc relation.
* ----------------
*/
typedef FormData_pg_amproc *Form_pg_amproc;
/* ----------------
* compiler constants for pg_amproc
* ----------------
*/
#define Natts_pg_amproc 5
#define Anum_pg_amproc_amprocfamily 1
#define Anum_pg_amproc_amproclefttype 2
#define Anum_pg_amproc_amprocrighttype 3
#define Anum_pg_amproc_amprocnum 4
#define Anum_pg_amproc_amproc 5
/* ----------------
* initial contents of pg_amproc
* ----------------
*/
/* btree */
DATA(insert ( 397 2277 2277 1 382 ));
DATA(insert ( 421 702 702 1 357 ));
DATA(insert ( 423 1560 1560 1 1596 ));
DATA(insert ( 424 16 16 1 1693 ));
DATA(insert ( 426 1042 1042 1 1078 ));
DATA(insert ( 428 17 17 1 1954 ));
DATA(insert ( 429 18 18 1 358 ));
DATA(insert ( 434 1082 1082 1 1092 ));
DATA(insert ( 434 1082 1114 1 2344 ));
DATA(insert ( 434 1082 1184 1 2357 ));
DATA(insert ( 434 1114 1114 1 2045 ));
DATA(insert ( 434 1114 1082 1 2370 ));
DATA(insert ( 434 1114 1184 1 2526 ));
DATA(insert ( 434 1184 1184 1 1314 ));
DATA(insert ( 434 1184 1082 1 2383 ));
DATA(insert ( 434 1184 1114 1 2533 ));
DATA(insert ( 1970 700 700 1 354 ));
DATA(insert ( 1970 700 701 1 2194 ));
DATA(insert ( 1970 701 701 1 355 ));
DATA(insert ( 1970 701 700 1 2195 ));
DATA(insert ( 1974 869 869 1 926 ));
DATA(insert ( 1976 21 21 1 350 ));
DATA(insert ( 1976 21 23 1 2190 ));
DATA(insert ( 1976 21 20 1 2192 ));
DATA(insert ( 1976 23 23 1 351 ));
DATA(insert ( 1976 23 20 1 2188 ));
DATA(insert ( 1976 23 21 1 2191 ));
DATA(insert ( 1976 20 20 1 842 ));
DATA(insert ( 1976 20 23 1 2189 ));
DATA(insert ( 1976 20 21 1 2193 ));
DATA(insert ( 1982 1186 1186 1 1315 ));
DATA(insert ( 1984 829 829 1 836 ));
DATA(insert ( 1986 19 19 1 359 ));
DATA(insert ( 1988 1700 1700 1 1769 ));
DATA(insert ( 1989 26 26 1 356 ));
DATA(insert ( 1991 30 30 1 404 ));
DATA(insert ( 2994 2249 2249 1 2987 ));
DATA(insert ( 1994 25 25 1 360 ));
DATA(insert ( 1996 1083 1083 1 1107 ));
DATA(insert ( 2000 1266 1266 1 1358 ));
DATA(insert ( 2002 1562 1562 1 1672 ));
DATA(insert ( 2095 25 25 1 2166 ));
DATA(insert ( 2097 1042 1042 1 2180 ));
DATA(insert ( 2099 790 790 1 377 ));
DATA(insert ( 2233 703 703 1 380 ));
DATA(insert ( 2234 704 704 1 381 ));
DATA(insert ( 2789 27 27 1 2794 ));
DATA(insert ( 2968 2950 2950 1 2960 ));
DATA(insert ( 3522 3500 3500 1 3514 ));
/* hash */
DATA(insert ( 427 1042 1042 1 1080 ));
DATA(insert ( 431 18 18 1 454 ));
DATA(insert ( 435 1082 1082 1 450 ));
DATA(insert ( 627 2277 2277 1 626 ));
DATA(insert ( 1971 700 700 1 451 ));
DATA(insert ( 1971 701 701 1 452 ));
DATA(insert ( 1975 869 869 1 422 ));
DATA(insert ( 1977 21 21 1 449 ));
DATA(insert ( 1977 23 23 1 450 ));
DATA(insert ( 1977 20 20 1 949 ));
DATA(insert ( 1983 1186 1186 1 1697 ));
DATA(insert ( 1985 829 829 1 399 ));
DATA(insert ( 1987 19 19 1 455 ));
DATA(insert ( 1990 26 26 1 453 ));
DATA(insert ( 1992 30 30 1 457 ));
DATA(insert ( 1995 25 25 1 400 ));
DATA(insert ( 1997 1083 1083 1 1688 ));
DATA(insert ( 1998 1700 1700 1 432 ));
DATA(insert ( 1999 1184 1184 1 2039 ));
DATA(insert ( 2001 1266 1266 1 1696 ));
DATA(insert ( 2040 1114 1114 1 2039 ));
DATA(insert ( 2222 16 16 1 454 ));
DATA(insert ( 2223 17 17 1 456 ));
DATA(insert ( 2224 22 22 1 398 ));
DATA(insert ( 2225 28 28 1 450 ));
DATA(insert ( 2226 29 29 1 450 ));
DATA(insert ( 2227 702 702 1 450 ));
DATA(insert ( 2228 703 703 1 450 ));
DATA(insert ( 2229 25 25 1 400 ));
DATA(insert ( 2231 1042 1042 1 1080 ));
DATA(insert ( 2235 1033 1033 1 329 ));
DATA(insert ( 2969 2950 2950 1 2963 ));
DATA(insert ( 3523 3500 3500 1 3515 ));
/* gist */
DATA(insert ( 2593 603 603 1 2578 ));
DATA(insert ( 2593 603 603 2 2583 ));
DATA(insert ( 2593 603 603 3 2579 ));
DATA(insert ( 2593 603 603 4 2580 ));
DATA(insert ( 2593 603 603 5 2581 ));
DATA(insert ( 2593 603 603 6 2582 ));
DATA(insert ( 2593 603 603 7 2584 ));
DATA(insert ( 2594 604 604 1 2585 ));
DATA(insert ( 2594 604 604 2 2583 ));
DATA(insert ( 2594 604 604 3 2586 ));
DATA(insert ( 2594 604 604 4 2580 ));
DATA(insert ( 2594 604 604 5 2581 ));
DATA(insert ( 2594 604 604 6 2582 ));
DATA(insert ( 2594 604 604 7 2584 ));
DATA(insert ( 2595 718 718 1 2591 ));
DATA(insert ( 2595 718 718 2 2583 ));
DATA(insert ( 2595 718 718 3 2592 ));
DATA(insert ( 2595 718 718 4 2580 ));
DATA(insert ( 2595 718 718 5 2581 ));
DATA(insert ( 2595 718 718 6 2582 ));
DATA(insert ( 2595 718 718 7 2584 ));
DATA(insert ( 3655 3614 3614 1 3654 ));
DATA(insert ( 3655 3614 3614 2 3651 ));
DATA(insert ( 3655 3614 3614 3 3648 ));
DATA(insert ( 3655 3614 3614 4 3649 ));
DATA(insert ( 3655 3614 3614 5 3653 ));
DATA(insert ( 3655 3614 3614 6 3650 ));
DATA(insert ( 3655 3614 3614 7 3652 ));
DATA(insert ( 3702 3615 3615 1 3701 ));
DATA(insert ( 3702 3615 3615 2 3698 ));
DATA(insert ( 3702 3615 3615 3 3695 ));
DATA(insert ( 3702 3615 3615 4 3696 ));
DATA(insert ( 3702 3615 3615 5 3700 ));
DATA(insert ( 3702 3615 3615 6 3697 ));
DATA(insert ( 3702 3615 3615 7 3699 ));
DATA(insert ( 1029 600 600 1 2179 ));
DATA(insert ( 1029 600 600 2 2583 ));
DATA(insert ( 1029 600 600 3 1030 ));
DATA(insert ( 1029 600 600 4 2580 ));
DATA(insert ( 1029 600 600 5 2581 ));
DATA(insert ( 1029 600 600 6 2582 ));
DATA(insert ( 1029 600 600 7 2584 ));
DATA(insert ( 1029 600 600 8 3064 ));
/* gin */
DATA(insert ( 2745 1007 1007 1 351 ));
DATA(insert ( 2745 1007 1007 2 2743 ));
DATA(insert ( 2745 1007 1007 3 2774 ));
DATA(insert ( 2745 1007 1007 4 2744 ));
DATA(insert ( 2745 1009 1009 1 360 ));
DATA(insert ( 2745 1009 1009 2 2743 ));
DATA(insert ( 2745 1009 1009 3 2774 ));
DATA(insert ( 2745 1009 1009 4 2744 ));
DATA(insert ( 2745 1015 1015 1 360 ));
DATA(insert ( 2745 1015 1015 2 2743 ));
DATA(insert ( 2745 1015 1015 3 2774 ));
DATA(insert ( 2745 1015 1015 4 2744 ));
DATA(insert ( 2745 1023 1023 1 357 ));
DATA(insert ( 2745 1023 1023 2 2743 ));
DATA(insert ( 2745 1023 1023 3 2774 ));
DATA(insert ( 2745 1023 1023 4 2744 ));
DATA(insert ( 2745 1561 1561 1 1596 ));
DATA(insert ( 2745 1561 1561 2 2743 ));
DATA(insert ( 2745 1561 1561 3 2774 ));
DATA(insert ( 2745 1561 1561 4 2744 ));
DATA(insert ( 2745 1000 1000 1 1693 ));
DATA(insert ( 2745 1000 1000 2 2743 ));
DATA(insert ( 2745 1000 1000 3 2774 ));
DATA(insert ( 2745 1000 1000 4 2744 ));
DATA(insert ( 2745 1014 1014 1 1078 ));
DATA(insert ( 2745 1014 1014 2 2743 ));
DATA(insert ( 2745 1014 1014 3 2774 ));
DATA(insert ( 2745 1014 1014 4 2744 ));
DATA(insert ( 2745 1001 1001 1 1954 ));
DATA(insert ( 2745 1001 1001 2 2743 ));
DATA(insert ( 2745 1001 1001 3 2774 ));
DATA(insert ( 2745 1001 1001 4 2744 ));
DATA(insert ( 2745 1002 1002 1 358 ));
DATA(insert ( 2745 1002 1002 2 2743 ));
DATA(insert ( 2745 1002 1002 3 2774 ));
DATA(insert ( 2745 1002 1002 4 2744 ));
DATA(insert ( 2745 1182 1182 1 1092 ));
DATA(insert ( 2745 1182 1182 2 2743 ));
DATA(insert ( 2745 1182 1182 3 2774 ));
DATA(insert ( 2745 1182 1182 4 2744 ));
DATA(insert ( 2745 1021 1021 1 354 ));
DATA(insert ( 2745 1021 1021 2 2743 ));
DATA(insert ( 2745 1021 1021 3 2774 ));
DATA(insert ( 2745 1021 1021 4 2744 ));
DATA(insert ( 2745 1022 1022 1 355 ));
DATA(insert ( 2745 1022 1022 2 2743 ));
DATA(insert ( 2745 1022 1022 3 2774 ));
DATA(insert ( 2745 1022 1022 4 2744 ));
DATA(insert ( 2745 1041 1041 1 926 ));
DATA(insert ( 2745 1041 1041 2 2743 ));
DATA(insert ( 2745 1041 1041 3 2774 ));
DATA(insert ( 2745 1041 1041 4 2744 ));
DATA(insert ( 2745 651 651 1 926 ));
DATA(insert ( 2745 651 651 2 2743 ));
DATA(insert ( 2745 651 651 3 2774 ));
DATA(insert ( 2745 651 651 4 2744 ));
DATA(insert ( 2745 1005 1005 1 350 ));
DATA(insert ( 2745 1005 1005 2 2743 ));
DATA(insert ( 2745 1005 1005 3 2774 ));
DATA(insert ( 2745 1005 1005 4 2744 ));
DATA(insert ( 2745 1016 1016 1 842 ));
DATA(insert ( 2745 1016 1016 2 2743 ));
DATA(insert ( 2745 1016 1016 3 2774 ));
DATA(insert ( 2745 1016 1016 4 2744 ));
DATA(insert ( 2745 1187 1187 1 1315 ));
DATA(insert ( 2745 1187 1187 2 2743 ));
DATA(insert ( 2745 1187 1187 3 2774 ));
DATA(insert ( 2745 1187 1187 4 2744 ));
DATA(insert ( 2745 1040 1040 1 836 ));
DATA(insert ( 2745 1040 1040 2 2743 ));
DATA(insert ( 2745 1040 1040 3 2774 ));
DATA(insert ( 2745 1040 1040 4 2744 ));
DATA(insert ( 2745 1003 1003 1 359 ));
DATA(insert ( 2745 1003 1003 2 2743 ));
DATA(insert ( 2745 1003 1003 3 2774 ));
DATA(insert ( 2745 1003 1003 4 2744 ));
DATA(insert ( 2745 1231 1231 1 1769 ));
DATA(insert ( 2745 1231 1231 2 2743 ));
DATA(insert ( 2745 1231 1231 3 2774 ));
DATA(insert ( 2745 1231 1231 4 2744 ));
DATA(insert ( 2745 1028 1028 1 356 ));
DATA(insert ( 2745 1028 1028 2 2743 ));
DATA(insert ( 2745 1028 1028 3 2774 ));
DATA(insert ( 2745 1028 1028 4 2744 ));
DATA(insert ( 2745 1013 1013 1 404 ));
DATA(insert ( 2745 1013 1013 2 2743 ));
DATA(insert ( 2745 1013 1013 3 2774 ));
DATA(insert ( 2745 1013 1013 4 2744 ));
DATA(insert ( 2745 1183 1183 1 1107 ));
DATA(insert ( 2745 1183 1183 2 2743 ));
DATA(insert ( 2745 1183 1183 3 2774 ));
DATA(insert ( 2745 1183 1183 4 2744 ));
DATA(insert ( 2745 1185 1185 1 1314 ));
DATA(insert ( 2745 1185 1185 2 2743 ));
DATA(insert ( 2745 1185 1185 3 2774 ));
DATA(insert ( 2745 1185 1185 4 2744 ));
DATA(insert ( 2745 1270 1270 1 1358 ));
DATA(insert ( 2745 1270 1270 2 2743 ));
DATA(insert ( 2745 1270 1270 3 2774 ));
DATA(insert ( 2745 1270 1270 4 2744 ));
DATA(insert ( 2745 1563 1563 1 1672 ));
DATA(insert ( 2745 1563 1563 2 2743 ));
DATA(insert ( 2745 1563 1563 3 2774 ));
DATA(insert ( 2745 1563 1563 4 2744 ));
DATA(insert ( 2745 1115 1115 1 2045 ));
DATA(insert ( 2745 1115 1115 2 2743 ));
DATA(insert ( 2745 1115 1115 3 2774 ));
DATA(insert ( 2745 1115 1115 4 2744 ));
DATA(insert ( 2745 791 791 1 377 ));
DATA(insert ( 2745 791 791 2 2743 ));
DATA(insert ( 2745 791 791 3 2774 ));
DATA(insert ( 2745 791 791 4 2744 ));
DATA(insert ( 2745 1024 1024 1 380 ));
DATA(insert ( 2745 1024 1024 2 2743 ));
DATA(insert ( 2745 1024 1024 3 2774 ));
DATA(insert ( 2745 1024 1024 4 2744 ));
DATA(insert ( 2745 1025 1025 1 381 ));
DATA(insert ( 2745 1025 1025 2 2743 ));
DATA(insert ( 2745 1025 1025 3 2774 ));
DATA(insert ( 2745 1025 1025 4 2744 ));
DATA(insert ( 3659 3614 3614 1 3724 ));
DATA(insert ( 3659 3614 3614 2 3656 ));
DATA(insert ( 3659 3614 3614 3 3657 ));
DATA(insert ( 3659 3614 3614 4 3658 ));
DATA(insert ( 3659 3614 3614 5 2700 ));
DATA(insert ( 3626 3614 3614 1 3622 ));
DATA(insert ( 3683 3615 3615 1 3668 ));
#endif /* PG_AMPROC_H */

56
deps/libpq/include/catalog/pg_attrdef.h vendored Normal file
View file

@ -0,0 +1,56 @@
/*-------------------------------------------------------------------------
*
* pg_attrdef.h
* definition of the system "attribute defaults" relation (pg_attrdef)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_attrdef.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_ATTRDEF_H
#define PG_ATTRDEF_H
#include "catalog/genbki.h"
/* ----------------
* pg_attrdef definition. cpp turns this into
* typedef struct FormData_pg_attrdef
* ----------------
*/
#define AttrDefaultRelationId 2604
CATALOG(pg_attrdef,2604)
{
Oid adrelid; /* OID of table containing attribute */
int2 adnum; /* attnum of attribute */
pg_node_tree adbin; /* nodeToString representation of default */
text adsrc; /* human-readable representation of default */
} FormData_pg_attrdef;
/* ----------------
* Form_pg_attrdef corresponds to a pointer to a tuple with
* the format of pg_attrdef relation.
* ----------------
*/
typedef FormData_pg_attrdef *Form_pg_attrdef;
/* ----------------
* compiler constants for pg_attrdef
* ----------------
*/
#define Natts_pg_attrdef 4
#define Anum_pg_attrdef_adrelid 1
#define Anum_pg_attrdef_adnum 2
#define Anum_pg_attrdef_adbin 3
#define Anum_pg_attrdef_adsrc 4
#endif /* PG_ATTRDEF_H */

View file

@ -0,0 +1,213 @@
/*-------------------------------------------------------------------------
*
* pg_attribute.h
* definition of the system "attribute" relation (pg_attribute)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_attribute.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_ATTRIBUTE_H
#define PG_ATTRIBUTE_H
#include "catalog/genbki.h"
/* ----------------
* pg_attribute definition. cpp turns this into
* typedef struct FormData_pg_attribute
*
* If you change the following, make sure you change the structs for
* system attributes in catalog/heap.c also.
* You may need to change catalog/genbki.pl as well.
* ----------------
*/
#define AttributeRelationId 1249
#define AttributeRelation_Rowtype_Id 75
CATALOG(pg_attribute,1249) BKI_BOOTSTRAP BKI_WITHOUT_OIDS BKI_ROWTYPE_OID(75) BKI_SCHEMA_MACRO
{
Oid attrelid; /* OID of relation containing this attribute */
NameData attname; /* name of attribute */
/*
* atttypid is the OID of the instance in Catalog Class pg_type that
* defines the data type of this attribute (e.g. int4). Information in
* that instance is redundant with the attlen, attbyval, and attalign
* attributes of this instance, so they had better match or Postgres will
* fail.
*/
Oid atttypid;
/*
* attstattarget is the target number of statistics datapoints to collect
* during VACUUM ANALYZE of this column. A zero here indicates that we do
* not wish to collect any stats about this column. A "-1" here indicates
* that no value has been explicitly set for this column, so ANALYZE
* should use the default setting.
*/
int4 attstattarget;
/*
* attlen is a copy of the typlen field from pg_type for this attribute.
* See atttypid comments above.
*/
int2 attlen;
/*
* attnum is the "attribute number" for the attribute: A value that
* uniquely identifies this attribute within its class. For user
* attributes, Attribute numbers are greater than 0 and not greater than
* the number of attributes in the class. I.e. if the Class pg_class says
* that Class XYZ has 10 attributes, then the user attribute numbers in
* Class pg_attribute must be 1-10.
*
* System attributes have attribute numbers less than 0 that are unique
* within the class, but not constrained to any particular range.
*
* Note that (attnum - 1) is often used as the index to an array.
*/
int2 attnum;
/*
* attndims is the declared number of dimensions, if an array type,
* otherwise zero.
*/
int4 attndims;
/*
* fastgetattr() uses attcacheoff to cache byte offsets of attributes in
* heap tuples. The value actually stored in pg_attribute (-1) indicates
* no cached value. But when we copy these tuples into a tuple
* descriptor, we may then update attcacheoff in the copies. This speeds
* up the attribute walking process.
*/
int4 attcacheoff;
/*
* atttypmod records type-specific data supplied at table creation time
* (for example, the max length of a varchar field). It is passed to
* type-specific input and output functions as the third argument. The
* value will generally be -1 for types that do not need typmod.
*/
int4 atttypmod;
/*
* attbyval is a copy of the typbyval field from pg_type for this
* attribute. See atttypid comments above.
*/
bool attbyval;
/*----------
* attstorage tells for VARLENA attributes, what the heap access
* methods can do to it if a given tuple doesn't fit into a page.
* Possible values are
* 'p': Value must be stored plain always
* 'e': Value can be stored in "secondary" relation (if relation
* has one, see pg_class.reltoastrelid)
* 'm': Value can be stored compressed inline
* 'x': Value can be stored compressed inline or in "secondary"
* Note that 'm' fields can also be moved out to secondary storage,
* but only as a last resort ('e' and 'x' fields are moved first).
*----------
*/
char attstorage;
/*
* attalign is a copy of the typalign field from pg_type for this
* attribute. See atttypid comments above.
*/
char attalign;
/* This flag represents the "NOT NULL" constraint */
bool attnotnull;
/* Has DEFAULT value or not */
bool atthasdef;
/* Is dropped (ie, logically invisible) or not */
bool attisdropped;
/* Has a local definition (hence, do not drop when attinhcount is 0) */
bool attislocal;
/* Number of times inherited from direct parent relation(s) */
int4 attinhcount;
/* attribute's collation */
Oid attcollation;
/*
* VARIABLE LENGTH FIELDS start here. These fields may be NULL, too.
*
* NOTE: the following fields are not present in tuple descriptors!
*/
/* Column-level access permissions */
aclitem attacl[1];
/* Column-level options */
text attoptions[1];
} FormData_pg_attribute;
/*
* ATTRIBUTE_FIXED_PART_SIZE is the size of the fixed-layout,
* guaranteed-not-null part of a pg_attribute row. This is in fact as much
* of the row as gets copied into tuple descriptors, so don't expect you
* can access fields beyond attcollation except in a real tuple!
*/
#define ATTRIBUTE_FIXED_PART_SIZE \
(offsetof(FormData_pg_attribute,attcollation) + sizeof(Oid))
/* ----------------
* Form_pg_attribute corresponds to a pointer to a tuple with
* the format of pg_attribute relation.
* ----------------
*/
typedef FormData_pg_attribute *Form_pg_attribute;
/* ----------------
* compiler constants for pg_attribute
* ----------------
*/
#define Natts_pg_attribute 20
#define Anum_pg_attribute_attrelid 1
#define Anum_pg_attribute_attname 2
#define Anum_pg_attribute_atttypid 3
#define Anum_pg_attribute_attstattarget 4
#define Anum_pg_attribute_attlen 5
#define Anum_pg_attribute_attnum 6
#define Anum_pg_attribute_attndims 7
#define Anum_pg_attribute_attcacheoff 8
#define Anum_pg_attribute_atttypmod 9
#define Anum_pg_attribute_attbyval 10
#define Anum_pg_attribute_attstorage 11
#define Anum_pg_attribute_attalign 12
#define Anum_pg_attribute_attnotnull 13
#define Anum_pg_attribute_atthasdef 14
#define Anum_pg_attribute_attisdropped 15
#define Anum_pg_attribute_attislocal 16
#define Anum_pg_attribute_attinhcount 17
#define Anum_pg_attribute_attcollation 18
#define Anum_pg_attribute_attacl 19
#define Anum_pg_attribute_attoptions 20
/* ----------------
* initial contents of pg_attribute
*
* The initial contents of pg_attribute are generated at compile time by
* genbki.pl. Only "bootstrapped" relations need be included.
* ----------------
*/
#endif /* PG_ATTRIBUTE_H */

View file

@ -0,0 +1,57 @@
/*-------------------------------------------------------------------------
*
* pg_auth_members.h
* definition of the system "authorization identifier members" relation
* (pg_auth_members) along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_auth_members.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AUTH_MEMBERS_H
#define PG_AUTH_MEMBERS_H
#include "catalog/genbki.h"
/* ----------------
* pg_auth_members definition. cpp turns this into
* typedef struct FormData_pg_auth_members
* ----------------
*/
#define AuthMemRelationId 1261
#define AuthMemRelation_Rowtype_Id 2843
CATALOG(pg_auth_members,1261) BKI_SHARED_RELATION BKI_WITHOUT_OIDS BKI_ROWTYPE_OID(2843) BKI_SCHEMA_MACRO
{
Oid roleid; /* ID of a role */
Oid member; /* ID of a member of that role */
Oid grantor; /* who granted the membership */
bool admin_option; /* granted with admin option? */
} FormData_pg_auth_members;
/* ----------------
* Form_pg_auth_members corresponds to a pointer to a tuple with
* the format of pg_auth_members relation.
* ----------------
*/
typedef FormData_pg_auth_members *Form_pg_auth_members;
/* ----------------
* compiler constants for pg_auth_members
* ----------------
*/
#define Natts_pg_auth_members 4
#define Anum_pg_auth_members_roleid 1
#define Anum_pg_auth_members_member 2
#define Anum_pg_auth_members_grantor 3
#define Anum_pg_auth_members_admin_option 4
#endif /* PG_AUTH_MEMBERS_H */

100
deps/libpq/include/catalog/pg_authid.h vendored Normal file
View file

@ -0,0 +1,100 @@
/*-------------------------------------------------------------------------
*
* pg_authid.h
* definition of the system "authorization identifier" relation (pg_authid)
* along with the relation's initial contents.
*
* pg_shadow and pg_group are now publicly accessible views on pg_authid.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_authid.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_AUTHID_H
#define PG_AUTHID_H
#include "catalog/genbki.h"
/*
* The CATALOG definition has to refer to the type of rolvaliduntil as
* "timestamptz" (lower case) so that bootstrap mode recognizes it. But
* the C header files define this type as TimestampTz. Since the field is
* potentially-null and therefore can't be accessed directly from C code,
* there is no particular need for the C struct definition to show the
* field type as TimestampTz --- instead we just make it int.
*/
#define timestamptz int
/* ----------------
* pg_authid definition. cpp turns this into
* typedef struct FormData_pg_authid
* ----------------
*/
#define AuthIdRelationId 1260
#define AuthIdRelation_Rowtype_Id 2842
CATALOG(pg_authid,1260) BKI_SHARED_RELATION BKI_ROWTYPE_OID(2842) BKI_SCHEMA_MACRO
{
NameData rolname; /* name of role */
bool rolsuper; /* read this field via superuser() only! */
bool rolinherit; /* inherit privileges from other roles? */
bool rolcreaterole; /* allowed to create more roles? */
bool rolcreatedb; /* allowed to create databases? */
bool rolcatupdate; /* allowed to alter catalogs manually? */
bool rolcanlogin; /* allowed to log in as session user? */
bool rolreplication; /* role used for streaming replication */
int4 rolconnlimit; /* max connections allowed (-1=no limit) */
/* remaining fields may be null; use heap_getattr to read them! */
text rolpassword; /* password, if any */
timestamptz rolvaliduntil; /* password expiration time, if any */
} FormData_pg_authid;
#undef timestamptz
/* ----------------
* Form_pg_authid corresponds to a pointer to a tuple with
* the format of pg_authid relation.
* ----------------
*/
typedef FormData_pg_authid *Form_pg_authid;
/* ----------------
* compiler constants for pg_authid
* ----------------
*/
#define Natts_pg_authid 11
#define Anum_pg_authid_rolname 1
#define Anum_pg_authid_rolsuper 2
#define Anum_pg_authid_rolinherit 3
#define Anum_pg_authid_rolcreaterole 4
#define Anum_pg_authid_rolcreatedb 5
#define Anum_pg_authid_rolcatupdate 6
#define Anum_pg_authid_rolcanlogin 7
#define Anum_pg_authid_rolreplication 8
#define Anum_pg_authid_rolconnlimit 9
#define Anum_pg_authid_rolpassword 10
#define Anum_pg_authid_rolvaliduntil 11
/* ----------------
* initial contents of pg_authid
*
* The uppercase quantities will be replaced at initdb time with
* user choices.
* ----------------
*/
DATA(insert OID = 10 ( "POSTGRES" t t t t t t t -1 _null_ _null_ ));
#define BOOTSTRAP_SUPERUSERID 10
#endif /* PG_AUTHID_H */

362
deps/libpq/include/catalog/pg_cast.h vendored Normal file
View file

@ -0,0 +1,362 @@
/*-------------------------------------------------------------------------
*
* pg_cast.h
* definition of the system "type casts" relation (pg_cast)
* along with the relation's initial contents.
*
* As of Postgres 8.0, pg_cast describes not only type coercion functions
* but also length coercion functions.
*
*
* Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/include/catalog/pg_cast.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CAST_H
#define PG_CAST_H
#include "catalog/genbki.h"
/* ----------------
* pg_cast definition. cpp turns this into
* typedef struct FormData_pg_cast
* ----------------
*/
#define CastRelationId 2605
CATALOG(pg_cast,2605)
{
Oid castsource; /* source datatype for cast */
Oid casttarget; /* destination datatype for cast */
Oid castfunc; /* cast function; 0 = binary coercible */
char castcontext; /* contexts in which cast can be used */
char castmethod; /* cast method */
} FormData_pg_cast;
typedef FormData_pg_cast *Form_pg_cast;
/*
* The allowable values for pg_cast.castcontext are specified by this enum.
* Since castcontext is stored as a "char", we use ASCII codes for human
* convenience in reading the table. Note that internally to the backend,
* these values are converted to the CoercionContext enum (see primnodes.h),
* which is defined to sort in a convenient order; the ASCII codes don't
* have to sort in any special order.
*/
typedef enum CoercionCodes
{
COERCION_CODE_IMPLICIT = 'i', /* coercion in context of expression */
COERCION_CODE_ASSIGNMENT = 'a', /* coercion in context of assignment */
COERCION_CODE_EXPLICIT = 'e' /* explicit cast operation */
} CoercionCodes;
/*
* The allowable values for pg_cast.castmethod are specified by this enum.
* Since castcontext is stored as a "char", we use ASCII codes for human
* convenience in reading the table.
*/
typedef enum CoercionMethod
{
COERCION_METHOD_FUNCTION = 'f', /* use a function */
COERCION_METHOD_BINARY = 'b', /* types are binary-compatible */
COERCION_METHOD_INOUT = 'i' /* use input/output functions */
} CoercionMethod;
/* ----------------
* compiler constants for pg_cast
* ----------------
*/
#define Natts_pg_cast 5
#define Anum_pg_cast_castsource 1
#define Anum_pg_cast_casttarget 2
#define Anum_pg_cast_castfunc 3
#define Anum_pg_cast_castcontext 4
#define Anum_pg_cast_castmethod 5
/* ----------------
* initial contents of pg_cast
*
* Note: this table has OIDs, but we don't bother to assign them manually,
* since nothing needs to know the specific OID of any built-in cast.
* ----------------
*/
/*
* Numeric category: implicit casts are allowed in the direction
* int2->int4->int8->numeric->float4->float8, while casts in the
* reverse direction are assignment-only.
*/
DATA(insert ( 20 21 714 a f ));
DATA(insert ( 20 23 480 a f ));
DATA(insert ( 20 700 652 i f ));
DATA(insert ( 20 701 482 i f ));
DATA(insert ( 20 1700 1781 i f ));
DATA(insert ( 21 20 754 i f ));
DATA(insert ( 21 23 313 i f ));
DATA(insert ( 21 700 236 i f ));
DATA(insert ( 21 701 235 i f ));
DATA(insert ( 21 1700 1782 i f ));
DATA(insert ( 23 20 481 i f ));
DATA(insert ( 23 21 314 a f ));
DATA(insert ( 23 700 318 i f ));
DATA(insert ( 23 701 316 i f ));
DATA(insert ( 23 1700 1740 i f ));
DATA(insert ( 700 20 653 a f ));
DATA(insert ( 700 21 238 a f ));
DATA(insert ( 700 23 319 a f ));
DATA(insert ( 700 701 311 i f ));
DATA(insert ( 700 1700 1742 a f ));
DATA(insert ( 701 20 483 a f ));
DATA(insert ( 701 21 237 a f ));
DATA(insert ( 701 23 317 a f ));
DATA(insert ( 701 700 312 a f ));
DATA(insert ( 701 1700 1743 a f ));
DATA(insert ( 1700 20 1779 a f ));
DATA(insert ( 1700 21 1783 a f ));
DATA(insert ( 1700 23 1744 a f ));
DATA(insert ( 1700 700 1745 i f ));
DATA(insert ( 1700 701 1746 i f ));
DATA(insert ( 790 1700 3823 a f ));
DATA(insert ( 1700 790 3824 a f ));
DATA(insert ( 23 790 3811 a f ));
DATA(insert ( 20 790 3812 a f ));
/* Allow explicit coercions between int4 and bool */
DATA(insert ( 23 16 2557 e f ));
DATA(insert ( 16 23 2558 e f ));
/*
* OID category: allow implicit conversion from any integral type (including
* int8, to support OID literals > 2G) to OID, as well as assignment coercion
* from OID to int4 or int8. Similarly for each OID-alias type. Also allow
* implicit coercions between OID and each OID-alias type, as well as
* regproc<->regprocedure and regoper<->regoperator. (Other coercions
* between alias types must pass through OID.) Lastly, there are implicit
* casts from text and varchar to regclass, which exist mainly to support
* legacy forms of nextval() and related functions.
*/
DATA(insert ( 20 26 1287 i f ));
DATA(insert ( 21 26 313 i f ));
DATA(insert ( 23 26 0 i b ));
DATA(insert ( 26 20 1288 a f ));
DATA(insert ( 26 23 0 a b ));
DATA(insert ( 26 24 0 i b ));
DATA(insert ( 24 26 0 i b ));
DATA(insert ( 20 24 1287 i f ));
DATA(insert ( 21 24 313 i f ));
DATA(insert ( 23 24 0 i b ));
DATA(insert ( 24 20 1288 a f ));
DATA(insert ( 24 23 0 a b ));
DATA(insert ( 24 2202 0 i b ));
DATA(insert ( 2202 24 0 i b ));
DATA(insert ( 26 2202 0 i b ));
DATA(insert ( 2202 26 0 i b ));
DATA(insert ( 20 2202 1287 i f ));
DATA(insert ( 21 2202 313 i f ));
DATA(insert ( 23 2202 0 i b ));
DATA(insert ( 2202 20 1288 a f ));
DATA(insert ( 2202 23 0 a b ));
DATA(insert ( 26 2203 0 i b ));
DATA(insert ( 2203 26 0 i b ));
DATA(insert ( 20 2203 1287 i f ));
DATA(insert ( 21 2203 313 i f ));
DATA(insert ( 23 2203 0 i b ));
DATA(insert ( 2203 20 1288 a f ));
DATA(insert ( 2203 23 0 a b ));
DATA(insert ( 2203 2204 0 i b ));
DATA(insert ( 2204 2203 0 i b ));
DATA(insert ( 26 2204 0 i b ));
DATA(insert ( 2204 26 0 i b ));
DATA(insert ( 20 2204 1287 i f ));
DATA(insert ( 21 2204 313 i f ));
DATA(insert ( 23 2204 0 i b ));
DATA(insert ( 2204 20 1288 a f ));
DATA(insert ( 2204 23 0 a b ));
DATA(insert ( 26 2205 0 i b ));
DATA(insert ( 2205 26 0 i b ));
DATA(insert ( 20 2205 1287 i f ));
DATA(insert ( 21 2205 313 i f ));
DATA(insert ( 23 2205 0 i b ));
DATA(insert ( 2205 20 1288 a f ));
DATA(insert ( 2205 23 0 a b ));
DATA(insert ( 26 2206 0 i b ));
DATA(insert ( 2206 26 0 i b ));
DATA(insert ( 20 2206 1287 i f ));
DATA(insert ( 21 2206 313 i f ));
DATA(insert ( 23 2206 0 i b ));
DATA(insert ( 2206 20 1288 a f ));
DATA(insert ( 2206 23 0 a b ));
DATA(insert ( 26 3734 0 i b ));
DATA(insert ( 3734 26 0 i b ));
DATA(insert ( 20 3734 1287 i f ));
DATA(insert ( 21 3734 313 i f ));
DATA(insert ( 23 3734 0 i b ));
DATA(insert ( 3734 20 1288 a f ));
DATA(insert ( 3734 23 0 a b ));
DATA(insert ( 26 3769 0 i b ));
DATA(insert ( 3769 26 0 i b ));
DATA(insert ( 20 3769 1287 i f ));
DATA(insert ( 21 3769 313 i f ));
DATA(insert ( 23 3769 0 i b ));
DATA(insert ( 3769 20 1288 a f ));
DATA(insert ( 3769 23 0 a b ));
DATA(insert ( 25 2205 1079 i f ));
DATA(insert ( 1043 2205 1079 i f ));
/*
* String category
*/
DATA(insert ( 25 1042 0 i b ));
DATA(insert ( 25 1043 0 i b ));
DATA(insert ( 1042 25 401 i f ));
DATA(insert ( 1042 1043 401 i f ));
DATA(insert ( 1043 25 0 i b ));
DATA(insert ( 1043 1042 0 i b ));
DATA(insert ( 18 25 946 i f ));
DATA(insert ( 18 1042 860 a f ));
DATA(insert ( 18 1043 946 a f ));
DATA(insert ( 19 25 406 i f ));
DATA(insert ( 19 1042 408 a f ));
DATA(insert ( 19 1043 1401 a f ));
DATA(insert ( 25 18 944 a f ));
DATA(insert ( 1042 18 944 a f ));
DATA(insert ( 1043 18 944 a f ));
DATA(insert ( 25 19 407 i f ));
DATA(insert ( 1042 19 409 i f ));
DATA(insert ( 1043 19 1400 i f ));
/* Allow explicit coercions between int4 and "char" */
DATA(insert ( 18 23 77 e f ));
DATA(insert ( 23 18 78 e f ));
/* pg_node_tree can be coerced to, but not from, text */
DATA(insert ( 194 25 0 i b ));
/*
* Datetime category
*/
DATA(insert ( 702 1082 1179 a f ));
DATA(insert ( 702 1083 1364 a f ));
DATA(insert ( 702 1114 2023 i f ));
DATA(insert ( 702 1184 1173 i f ));
DATA(insert ( 703 1186 1177 i f ));
DATA(insert ( 1082 1114 2024 i f ));
DATA(insert ( 1082 1184 1174 i f ));
DATA(insert ( 1083 1186 1370 i f ));
DATA(insert ( 1083 1266 2047 i f ));
DATA(insert ( 1114 702 2030 a f ));
DATA(insert ( 1114 1082 2029 a f ));
DATA(insert ( 1114 1083 1316 a f ));
DATA(insert ( 1114 1184 2028 i f ));
DATA(insert ( 1184 702 1180 a f ));
DATA(insert ( 1184 1082 1178 a f ));
DATA(insert ( 1184 1083 2019 a f ));
DATA(insert ( 1184 1114 2027 a f ));
DATA(insert ( 1184 1266 1388 a f ));
DATA(insert ( 1186 703 1194 a f ));
DATA(insert ( 1186 1083 1419 a f ));
DATA(insert ( 1266 1083 2046 a f ));
/* Cross-category casts between int4 and abstime, reltime */
DATA(insert ( 23 702 0 e b ));
DATA(insert ( 702 23 0 e b ));
DATA(insert ( 23 703 0 e b ));
DATA(insert ( 703 23 0 e b ));
/*
* Geometric category
*/
DATA(insert ( 601 600 1532 e f ));
DATA(insert ( 602 600 1533 e f ));
DATA(insert ( 602 604 1449 a f ));
DATA(insert ( 603 600 1534 e f ));
DATA(insert ( 603 601 1541 e f ));
DATA(insert ( 603 604 1448 a f ));
DATA(insert ( 603 718 1479 e f ));
DATA(insert ( 604 600 1540 e f ));
DATA(insert ( 604 602 1447 a f ));
DATA(insert ( 604 603 1446 e f ));
DATA(insert ( 604 718 1474 e f ));
DATA(insert ( 718 600 1416 e f ));
DATA(insert ( 718 603 1480 e f ));
DATA(insert ( 718 604 1544 e f ));
/*
* INET category
*/
DATA(insert ( 650 869 0 i b ));
DATA(insert ( 869 650 1715 a f ));
/*
* BitString category
*/
DATA(insert ( 1560 1562 0 i b ));
DATA(insert ( 1562 1560 0 i b ));
/* Cross-category casts between bit and int4, int8 */
DATA(insert ( 20 1560 2075 e f ));
DATA(insert ( 23 1560 1683 e f ));
DATA(insert ( 1560 20 2076 e f ));
DATA(insert ( 1560 23 1684 e f ));
/*
* Cross-category casts to and from TEXT
*
* We need entries here only for a few specialized cases where the behavior
* of the cast function differs from the datatype's I/O functions. Otherwise,
* parse_coerce.c will generate CoerceViaIO operations without any prompting.
*
* Note that the castcontext values specified here should be no stronger than
* parse_coerce.c's automatic casts ('a' to text, 'e' from text) else odd
* behavior will ensue when the automatic cast is applied instead of the
* pg_cast entry!
*/
DATA(insert ( 650 25 730 a f ));
DATA(insert ( 869 25 730 a f ));
DATA(insert ( 16 25 2971 a f ));
DATA(insert ( 142 25 0 a b ));
DATA(insert ( 25 142 2896 e f ));
/*
* Cross-category casts to and from VARCHAR
*
* We support all the same casts as for TEXT.
*/
DATA(insert ( 650 1043 730 a f ));
DATA(insert ( 869 1043 730 a f ));
DATA(insert ( 16 1043 2971 a f ));
DATA(insert ( 142 1043 0 a b ));
DATA(insert ( 1043 142 2896 e f ));
/*
* Cross-category casts to and from BPCHAR
*
* We support all the same casts as for TEXT.
*/
DATA(insert ( 650 1042 730 a f ));
DATA(insert ( 869 1042 730 a f ));
DATA(insert ( 16 1042 2971 a f ));
DATA(insert ( 142 1042 0 a b ));
DATA(insert ( 1042 142 2896 e f ));
/*
* Length-coercion functions
*/
DATA(insert ( 1042 1042 668 i f ));
DATA(insert ( 1043 1043 669 i f ));
DATA(insert ( 1083 1083 1968 i f ));
DATA(insert ( 1114 1114 1961 i f ));
DATA(insert ( 1184 1184 1967 i f ));
DATA(insert ( 1186 1186 1200 i f ));
DATA(insert ( 1266 1266 1969 i f ));
DATA(insert ( 1560 1560 1685 i f ));
DATA(insert ( 1562 1562 1687 i f ));
DATA(insert ( 1700 1700 1703 i f ));
#endif /* PG_CAST_H */

156
deps/libpq/include/catalog/pg_class.h vendored Normal file
View file

@ -0,0 +1,156 @@
/*-------------------------------------------------------------------------
*
* pg_class.h
* definition of the system "relation" relation (pg_class)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_class.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CLASS_H
#define PG_CLASS_H
#include "catalog/genbki.h"
/* ----------------
* pg_class definition. cpp turns this into
* typedef struct FormData_pg_class
* ----------------
*/
#define RelationRelationId 1259
#define RelationRelation_Rowtype_Id 83
CATALOG(pg_class,1259) BKI_BOOTSTRAP BKI_ROWTYPE_OID(83) BKI_SCHEMA_MACRO
{
NameData relname; /* class name */
Oid relnamespace; /* OID of namespace containing this class */
Oid reltype; /* OID of entry in pg_type for table's
* implicit row type */
Oid reloftype; /* OID of entry in pg_type for underlying
* composite type */
Oid relowner; /* class owner */
Oid relam; /* index access method; 0 if not an index */
Oid relfilenode; /* identifier of physical storage file */
/* relfilenode == 0 means it is a "mapped" relation, see relmapper.c */
Oid reltablespace; /* identifier of table space for relation */
int4 relpages; /* # of blocks (not always up-to-date) */
float4 reltuples; /* # of tuples (not always up-to-date) */
Oid reltoastrelid; /* OID of toast table; 0 if none */
Oid reltoastidxid; /* if toast table, OID of chunk_id index */
bool relhasindex; /* T if has (or has had) any indexes */
bool relisshared; /* T if shared across databases */
char relpersistence; /* see RELPERSISTENCE_xxx constants below */
char relkind; /* see RELKIND_xxx constants below */
int2 relnatts; /* number of user attributes */
/*
* Class pg_attribute must contain exactly "relnatts" user attributes
* (with attnums ranging from 1 to relnatts) for this class. It may also
* contain entries with negative attnums for system attributes.
*/
int2 relchecks; /* # of CHECK constraints for class */
bool relhasoids; /* T if we generate OIDs for rows of rel */
bool relhaspkey; /* has (or has had) PRIMARY KEY index */
bool relhasrules; /* has (or has had) any rules */
bool relhastriggers; /* has (or has had) any TRIGGERs */
bool relhassubclass; /* has (or has had) derived classes */
TransactionId relfrozenxid; /* all Xids < this are frozen in this rel */
/*
* VARIABLE LENGTH FIELDS start here. These fields may be NULL, too.
*
* NOTE: these fields are not present in a relcache entry's rd_rel field.
*/
aclitem relacl[1]; /* access permissions */
text reloptions[1]; /* access-method-specific options */
} FormData_pg_class;
/* Size of fixed part of pg_class tuples, not counting var-length fields */
#define CLASS_TUPLE_SIZE \
(offsetof(FormData_pg_class,relfrozenxid) + sizeof(TransactionId))
/* ----------------
* Form_pg_class corresponds to a pointer to a tuple with
* the format of pg_class relation.
* ----------------
*/
typedef FormData_pg_class *Form_pg_class;
/* ----------------
* compiler constants for pg_class
* ----------------
*/
#define Natts_pg_class 26
#define Anum_pg_class_relname 1
#define Anum_pg_class_relnamespace 2
#define Anum_pg_class_reltype 3
#define Anum_pg_class_reloftype 4
#define Anum_pg_class_relowner 5
#define Anum_pg_class_relam 6
#define Anum_pg_class_relfilenode 7
#define Anum_pg_class_reltablespace 8
#define Anum_pg_class_relpages 9
#define Anum_pg_class_reltuples 10
#define Anum_pg_class_reltoastrelid 11
#define Anum_pg_class_reltoastidxid 12
#define Anum_pg_class_relhasindex 13
#define Anum_pg_class_relisshared 14
#define Anum_pg_class_relpersistence 15
#define Anum_pg_class_relkind 16
#define Anum_pg_class_relnatts 17
#define Anum_pg_class_relchecks 18
#define Anum_pg_class_relhasoids 19
#define Anum_pg_class_relhaspkey 20
#define Anum_pg_class_relhasrules 21
#define Anum_pg_class_relhastriggers 22
#define Anum_pg_class_relhassubclass 23
#define Anum_pg_class_relfrozenxid 24
#define Anum_pg_class_relacl 25
#define Anum_pg_class_reloptions 26
/* ----------------
* initial contents of pg_class
*
* NOTE: only "bootstrapped" relations need to be declared here. Be sure that
* the OIDs listed here match those given in their CATALOG macros, and that
* the relnatts values are correct.
* ----------------
*/
/* Note: "3" in the relfrozenxid column stands for FirstNormalTransactionId */
DATA(insert OID = 1247 ( pg_type PGNSP 71 0 PGUID 0 0 0 0 0 0 0 f f p r 29 0 t f f f f 3 _null_ _null_ ));
DESCR("");
DATA(insert OID = 1249 ( pg_attribute PGNSP 75 0 PGUID 0 0 0 0 0 0 0 f f p r 20 0 f f f f f 3 _null_ _null_ ));
DESCR("");
DATA(insert OID = 1255 ( pg_proc PGNSP 81 0 PGUID 0 0 0 0 0 0 0 f f p r 25 0 t f f f f 3 _null_ _null_ ));
DESCR("");
DATA(insert OID = 1259 ( pg_class PGNSP 83 0 PGUID 0 0 0 0 0 0 0 f f p r 26 0 t f f f f 3 _null_ _null_ ));
DESCR("");
#define RELKIND_RELATION 'r' /* ordinary table */
#define RELKIND_INDEX 'i' /* secondary index */
#define RELKIND_SEQUENCE 'S' /* sequence object */
#define RELKIND_TOASTVALUE 't' /* for out-of-line values */
#define RELKIND_VIEW 'v' /* view */
#define RELKIND_COMPOSITE_TYPE 'c' /* composite type */
#define RELKIND_FOREIGN_TABLE 'f' /* foreign table */
#define RELKIND_UNCATALOGED 'u' /* not yet cataloged */
#define RELPERSISTENCE_PERMANENT 'p' /* regular table */
#define RELPERSISTENCE_UNLOGGED 'u' /* unlogged permanent table */
#define RELPERSISTENCE_TEMP 't' /* temporary table */
#endif /* PG_CLASS_H */

View file

@ -0,0 +1,76 @@
/*-------------------------------------------------------------------------
*
* pg_collation.h
* definition of the system "collation" relation (pg_collation)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* src/include/catalog/pg_collation.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_COLLATION_H
#define PG_COLLATION_H
#include "catalog/genbki.h"
/* ----------------
* pg_collation definition. cpp turns this into
* typedef struct FormData_pg_collation
* ----------------
*/
#define CollationRelationId 3456
CATALOG(pg_collation,3456)
{
NameData collname; /* collation name */
Oid collnamespace; /* OID of namespace containing collation */
Oid collowner; /* owner of collation */
int4 collencoding; /* encoding for this collation; -1 = "all" */
NameData collcollate; /* LC_COLLATE setting */
NameData collctype; /* LC_CTYPE setting */
} FormData_pg_collation;
/* ----------------
* Form_pg_collation corresponds to a pointer to a row with
* the format of pg_collation relation.
* ----------------
*/
typedef FormData_pg_collation *Form_pg_collation;
/* ----------------
* compiler constants for pg_collation
* ----------------
*/
#define Natts_pg_collation 6
#define Anum_pg_collation_collname 1
#define Anum_pg_collation_collnamespace 2
#define Anum_pg_collation_collowner 3
#define Anum_pg_collation_collencoding 4
#define Anum_pg_collation_collcollate 5
#define Anum_pg_collation_collctype 6
/* ----------------
* initial contents of pg_collation
* ----------------
*/
DATA(insert OID = 100 ( default PGNSP PGUID -1 "" "" ));
DESCR("database's default collation");
#define DEFAULT_COLLATION_OID 100
DATA(insert OID = 950 ( C PGNSP PGUID -1 "C" "C" ));
DESCR("standard C collation");
#define C_COLLATION_OID 950
DATA(insert OID = 951 ( POSIX PGNSP PGUID -1 "POSIX" "POSIX" ));
DESCR("standard POSIX collation");
#define POSIX_COLLATION_OID 951
#endif /* PG_COLLATION_H */

View file

@ -0,0 +1,23 @@
/*-------------------------------------------------------------------------
*
* pg_collation_fn.h
* prototypes for functions in catalog/pg_collation.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_collation_fn.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_COLLATION_FN_H
#define PG_COLLATION_FN_H
extern Oid CollationCreate(const char *collname, Oid collnamespace,
Oid collowner,
int32 collencoding,
const char *collcollate, const char *collctype);
extern void RemoveCollationById(Oid collationOid);
#endif /* PG_COLLATION_FN_H */

View file

@ -0,0 +1,251 @@
/*-------------------------------------------------------------------------
*
* pg_constraint.h
* definition of the system "constraint" relation (pg_constraint)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_constraint.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CONSTRAINT_H
#define PG_CONSTRAINT_H
#include "catalog/genbki.h"
#include "nodes/pg_list.h"
/* ----------------
* pg_constraint definition. cpp turns this into
* typedef struct FormData_pg_constraint
* ----------------
*/
#define ConstraintRelationId 2606
CATALOG(pg_constraint,2606)
{
/*
* conname + connamespace is deliberately not unique; we allow, for
* example, the same name to be used for constraints of different
* relations. This is partly for backwards compatibility with past
* Postgres practice, and partly because we don't want to have to obtain a
* global lock to generate a globally unique name for a nameless
* constraint. We associate a namespace with constraint names only for
* SQL-spec compatibility.
*/
NameData conname; /* name of this constraint */
Oid connamespace; /* OID of namespace containing constraint */
char contype; /* constraint type; see codes below */
bool condeferrable; /* deferrable constraint? */
bool condeferred; /* deferred by default? */
bool convalidated; /* constraint has been validated? */
/*
* conrelid and conkey are only meaningful if the constraint applies to a
* specific relation (this excludes domain constraints and assertions).
* Otherwise conrelid is 0 and conkey is NULL.
*/
Oid conrelid; /* relation this constraint constrains */
/*
* contypid links to the pg_type row for a domain if this is a domain
* constraint. Otherwise it's 0.
*
* For SQL-style global ASSERTIONs, both conrelid and contypid would be
* zero. This is not presently supported, however.
*/
Oid contypid; /* domain this constraint constrains */
/*
* conindid links to the index supporting the constraint, if any;
* otherwise it's 0. This is used for unique, primary-key, and exclusion
* constraints, and less obviously for foreign-key constraints (where the
* index is a unique index on the referenced relation's referenced
* columns). Notice that the index is on conrelid in the first case but
* confrelid in the second.
*/
Oid conindid; /* index supporting this constraint */
/*
* These fields, plus confkey, are only meaningful for a foreign-key
* constraint. Otherwise confrelid is 0 and the char fields are spaces.
*/
Oid confrelid; /* relation referenced by foreign key */
char confupdtype; /* foreign key's ON UPDATE action */
char confdeltype; /* foreign key's ON DELETE action */
char confmatchtype; /* foreign key's match type */
/* Has a local definition (hence, do not drop when coninhcount is 0) */
bool conislocal;
/* Number of times inherited from direct parent relation(s) */
int4 coninhcount;
/*
* VARIABLE LENGTH FIELDS start here. These fields may be NULL, too.
*/
/*
* Columns of conrelid that the constraint applies to, if known (this is
* NULL for trigger constraints)
*/
int2 conkey[1];
/*
* If a foreign key, the referenced columns of confrelid
*/
int2 confkey[1];
/*
* If a foreign key, the OIDs of the PK = FK equality operators for each
* column of the constraint
*/
Oid conpfeqop[1];
/*
* If a foreign key, the OIDs of the PK = PK equality operators for each
* column of the constraint (i.e., equality for the referenced columns)
*/
Oid conppeqop[1];
/*
* If a foreign key, the OIDs of the FK = FK equality operators for each
* column of the constraint (i.e., equality for the referencing columns)
*/
Oid conffeqop[1];
/*
* If an exclusion constraint, the OIDs of the exclusion operators for
* each column of the constraint
*/
Oid conexclop[1];
/*
* If a check constraint, nodeToString representation of expression
*/
pg_node_tree conbin;
/*
* If a check constraint, source-text representation of expression
*/
text consrc;
} FormData_pg_constraint;
/* ----------------
* Form_pg_constraint corresponds to a pointer to a tuple with
* the format of pg_constraint relation.
* ----------------
*/
typedef FormData_pg_constraint *Form_pg_constraint;
/* ----------------
* compiler constants for pg_constraint
* ----------------
*/
#define Natts_pg_constraint 23
#define Anum_pg_constraint_conname 1
#define Anum_pg_constraint_connamespace 2
#define Anum_pg_constraint_contype 3
#define Anum_pg_constraint_condeferrable 4
#define Anum_pg_constraint_condeferred 5
#define Anum_pg_constraint_convalidated 6
#define Anum_pg_constraint_conrelid 7
#define Anum_pg_constraint_contypid 8
#define Anum_pg_constraint_conindid 9
#define Anum_pg_constraint_confrelid 10
#define Anum_pg_constraint_confupdtype 11
#define Anum_pg_constraint_confdeltype 12
#define Anum_pg_constraint_confmatchtype 13
#define Anum_pg_constraint_conislocal 14
#define Anum_pg_constraint_coninhcount 15
#define Anum_pg_constraint_conkey 16
#define Anum_pg_constraint_confkey 17
#define Anum_pg_constraint_conpfeqop 18
#define Anum_pg_constraint_conppeqop 19
#define Anum_pg_constraint_conffeqop 20
#define Anum_pg_constraint_conexclop 21
#define Anum_pg_constraint_conbin 22
#define Anum_pg_constraint_consrc 23
/* Valid values for contype */
#define CONSTRAINT_CHECK 'c'
#define CONSTRAINT_FOREIGN 'f'
#define CONSTRAINT_PRIMARY 'p'
#define CONSTRAINT_UNIQUE 'u'
#define CONSTRAINT_TRIGGER 't'
#define CONSTRAINT_EXCLUSION 'x'
/*
* Valid values for confupdtype and confdeltype are the FKCONSTR_ACTION_xxx
* constants defined in parsenodes.h. Valid values for confmatchtype are
* the FKCONSTR_MATCH_xxx constants defined in parsenodes.h.
*/
/*
* Identify constraint type for lookup purposes
*/
typedef enum ConstraintCategory
{
CONSTRAINT_RELATION,
CONSTRAINT_DOMAIN,
CONSTRAINT_ASSERTION /* for future expansion */
} ConstraintCategory;
/*
* prototypes for functions in pg_constraint.c
*/
extern Oid CreateConstraintEntry(const char *constraintName,
Oid constraintNamespace,
char constraintType,
bool isDeferrable,
bool isDeferred,
bool isValidated,
Oid relId,
const int16 *constraintKey,
int constraintNKeys,
Oid domainId,
Oid indexRelId,
Oid foreignRelId,
const int16 *foreignKey,
const Oid *pfEqOp,
const Oid *ppEqOp,
const Oid *ffEqOp,
int foreignNKeys,
char foreignUpdateType,
char foreignDeleteType,
char foreignMatchType,
const Oid *exclOp,
Node *conExpr,
const char *conBin,
const char *conSrc,
bool conIsLocal,
int conInhCount);
extern void RemoveConstraintById(Oid conId);
extern void RenameConstraintById(Oid conId, const char *newname);
extern void SetValidatedConstraintById(Oid conId);
extern bool ConstraintNameIsUsed(ConstraintCategory conCat, Oid objId,
Oid objNamespace, const char *conname);
extern char *ChooseConstraintName(const char *name1, const char *name2,
const char *label, Oid namespaceid,
List *others);
extern void AlterConstraintNamespaces(Oid ownerId, Oid oldNspId,
Oid newNspId, bool isType);
extern Oid get_constraint_oid(Oid relid, const char *conname, bool missing_ok);
extern bool check_functional_grouping(Oid relid,
Index varno, Index varlevelsup,
List *grouping_columns,
List **constraintDeps);
#endif /* PG_CONSTRAINT_H */

204
deps/libpq/include/catalog/pg_control.h vendored Normal file
View file

@ -0,0 +1,204 @@
/*-------------------------------------------------------------------------
*
* pg_control.h
* The system control file "pg_control" is not a heap relation.
* However, we define it here so that the format is documented.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_control.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CONTROL_H
#define PG_CONTROL_H
#include "access/xlogdefs.h"
#include "pgtime.h" /* for pg_time_t */
#include "utils/pg_crc.h"
/* Version identifier for this pg_control format */
#define PG_CONTROL_VERSION 903
/*
* Body of CheckPoint XLOG records. This is declared here because we keep
* a copy of the latest one in pg_control for possible disaster recovery.
* Changing this struct requires a PG_CONTROL_VERSION bump.
*/
typedef struct CheckPoint
{
XLogRecPtr redo; /* next RecPtr available when we began to
* create CheckPoint (i.e. REDO start point) */
TimeLineID ThisTimeLineID; /* current TLI */
uint32 nextXidEpoch; /* higher-order bits of nextXid */
TransactionId nextXid; /* next free XID */
Oid nextOid; /* next free OID */
MultiXactId nextMulti; /* next free MultiXactId */
MultiXactOffset nextMultiOffset; /* next free MultiXact offset */
TransactionId oldestXid; /* cluster-wide minimum datfrozenxid */
Oid oldestXidDB; /* database with minimum datfrozenxid */
pg_time_t time; /* time stamp of checkpoint */
/*
* Oldest XID still running. This is only needed to initialize hot standby
* mode from an online checkpoint, so we only bother calculating this for
* online checkpoints and only when wal_level is hot_standby. Otherwise
* it's set to InvalidTransactionId.
*/
TransactionId oldestActiveXid;
} CheckPoint;
/* XLOG info values for XLOG rmgr */
#define XLOG_CHECKPOINT_SHUTDOWN 0x00
#define XLOG_CHECKPOINT_ONLINE 0x10
#define XLOG_NOOP 0x20
#define XLOG_NEXTOID 0x30
#define XLOG_SWITCH 0x40
#define XLOG_BACKUP_END 0x50
#define XLOG_PARAMETER_CHANGE 0x60
#define XLOG_RESTORE_POINT 0x70
/*
* System status indicator. Note this is stored in pg_control; if you change
* it, you must bump PG_CONTROL_VERSION
*/
typedef enum DBState
{
DB_STARTUP = 0,
DB_SHUTDOWNED,
DB_SHUTDOWNED_IN_RECOVERY,
DB_SHUTDOWNING,
DB_IN_CRASH_RECOVERY,
DB_IN_ARCHIVE_RECOVERY,
DB_IN_PRODUCTION
} DBState;
/*
* Contents of pg_control.
*
* NOTE: try to keep this under 512 bytes so that it will fit on one physical
* sector of typical disk drives. This reduces the odds of corruption due to
* power failure midway through a write.
*/
typedef struct ControlFileData
{
/*
* Unique system identifier --- to ensure we match up xlog files with the
* installation that produced them.
*/
uint64 system_identifier;
/*
* Version identifier information. Keep these fields at the same offset,
* especially pg_control_version; they won't be real useful if they move
* around. (For historical reasons they must be 8 bytes into the file
* rather than immediately at the front.)
*
* pg_control_version identifies the format of pg_control itself.
* catalog_version_no identifies the format of the system catalogs.
*
* There are additional version identifiers in individual files; for
* example, WAL logs contain per-page magic numbers that can serve as
* version cues for the WAL log.
*/
uint32 pg_control_version; /* PG_CONTROL_VERSION */
uint32 catalog_version_no; /* see catversion.h */
/*
* System status data
*/
DBState state; /* see enum above */
pg_time_t time; /* time stamp of last pg_control update */
XLogRecPtr checkPoint; /* last check point record ptr */
XLogRecPtr prevCheckPoint; /* previous check point record ptr */
CheckPoint checkPointCopy; /* copy of last check point record */
/*
* These two values determine the minimum point we must recover up to
* before starting up:
*
* minRecoveryPoint is updated to the latest replayed LSN whenever we
* flush a data change during archive recovery. That guards against
* starting archive recovery, aborting it, and restarting with an earlier
* stop location. If we've already flushed data changes from WAL record X
* to disk, we mustn't start up until we reach X again. Zero when not
* doing archive recovery.
*
* backupStartPoint is the redo pointer of the backup start checkpoint, if
* we are recovering from an online backup and haven't reached the end of
* backup yet. It is reset to zero when the end of backup is reached, and
* we mustn't start up before that. A boolean would suffice otherwise, but
* we use the redo pointer as a cross-check when we see an end-of-backup
* record, to make sure the end-of-backup record corresponds the base
* backup we're recovering from.
*/
XLogRecPtr minRecoveryPoint;
XLogRecPtr backupStartPoint;
/*
* Parameter settings that determine if the WAL can be used for archival
* or hot standby.
*/
int wal_level;
int MaxConnections;
int max_prepared_xacts;
int max_locks_per_xact;
/*
* This data is used to check for hardware-architecture compatibility of
* the database and the backend executable. We need not check endianness
* explicitly, since the pg_control version will surely look wrong to a
* machine of different endianness, but we do need to worry about MAXALIGN
* and floating-point format. (Note: storage layout nominally also
* depends on SHORTALIGN and INTALIGN, but in practice these are the same
* on all architectures of interest.)
*
* Testing just one double value is not a very bulletproof test for
* floating-point compatibility, but it will catch most cases.
*/
uint32 maxAlign; /* alignment requirement for tuples */
double floatFormat; /* constant 1234567.0 */
#define FLOATFORMAT_VALUE 1234567.0
/*
* This data is used to make sure that configuration of this database is
* compatible with the backend executable.
*/
uint32 blcksz; /* data block size for this DB */
uint32 relseg_size; /* blocks per segment of large relation */
uint32 xlog_blcksz; /* block size within WAL files */
uint32 xlog_seg_size; /* size of each WAL segment */
uint32 nameDataLen; /* catalog name field width */
uint32 indexMaxKeys; /* max number of columns in an index */
uint32 toast_max_chunk_size; /* chunk size in TOAST tables */
/* flag indicating internal format of timestamp, interval, time */
bool enableIntTimes; /* int64 storage enabled? */
/* flags indicating pass-by-value status of various types */
bool float4ByVal; /* float4 pass-by-value? */
bool float8ByVal; /* float8, int8, etc pass-by-value? */
/* CRC of all above ... MUST BE LAST! */
pg_crc32 crc;
} ControlFileData;
/*
* Physical size of the pg_control file. Note that this is considerably
* bigger than the actually used size (ie, sizeof(ControlFileData)).
* The idea is to keep the physical size constant independent of format
* changes, so that ReadControlFile will deliver a suitable wrong-version
* message instead of a read error if it's looking at an incompatible file.
*/
#define PG_CONTROL_SIZE 8192
#endif /* PG_CONTROL_H */

View file

@ -0,0 +1,77 @@
/*-------------------------------------------------------------------------
*
* pg_conversion.h
* definition of the system "conversion" relation (pg_conversion)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_conversion.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CONVERSION_H
#define PG_CONVERSION_H
#include "catalog/genbki.h"
/* ----------------------------------------------------------------
* pg_conversion definition.
*
* cpp turns this into typedef struct FormData_pg_namespace
*
* conname name of the conversion
* connamespace name space which the conversion belongs to
* conowner owner of the conversion
* conforencoding FOR encoding id
* contoencoding TO encoding id
* conproc OID of the conversion proc
* condefault TRUE if this is a default conversion
* ----------------------------------------------------------------
*/
#define ConversionRelationId 2607
CATALOG(pg_conversion,2607)
{
NameData conname;
Oid connamespace;
Oid conowner;
int4 conforencoding;
int4 contoencoding;
regproc conproc;
bool condefault;
} FormData_pg_conversion;
/* ----------------
* Form_pg_conversion corresponds to a pointer to a tuple with
* the format of pg_conversion relation.
* ----------------
*/
typedef FormData_pg_conversion *Form_pg_conversion;
/* ----------------
* compiler constants for pg_conversion
* ----------------
*/
#define Natts_pg_conversion 7
#define Anum_pg_conversion_conname 1
#define Anum_pg_conversion_connamespace 2
#define Anum_pg_conversion_conowner 3
#define Anum_pg_conversion_conforencoding 4
#define Anum_pg_conversion_contoencoding 5
#define Anum_pg_conversion_conproc 6
#define Anum_pg_conversion_condefault 7
/* ----------------
* initial contents of pg_conversion
* ---------------
*/
#endif /* PG_CONVERSION_H */

View file

@ -0,0 +1,24 @@
/*-------------------------------------------------------------------------
*
* pg_conversion_fn.h
* prototypes for functions in catalog/pg_conversion.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_conversion_fn.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_CONVERSION_FN_H
#define PG_CONVERSION_FN_H
extern Oid ConversionCreate(const char *conname, Oid connamespace,
Oid conowner,
int32 conforencoding, int32 contoencoding,
Oid conproc, bool def);
extern void RemoveConversionById(Oid conversionOid);
extern Oid FindDefaultConversion(Oid connamespace, int32 for_encoding, int32 to_encoding);
#endif /* PG_CONVERSION_FN_H */

View file

@ -0,0 +1,77 @@
/*-------------------------------------------------------------------------
*
* pg_database.h
* definition of the system "database" relation (pg_database)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_database.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_DATABASE_H
#define PG_DATABASE_H
#include "catalog/genbki.h"
/* ----------------
* pg_database definition. cpp turns this into
* typedef struct FormData_pg_database
* ----------------
*/
#define DatabaseRelationId 1262
#define DatabaseRelation_Rowtype_Id 1248
CATALOG(pg_database,1262) BKI_SHARED_RELATION BKI_ROWTYPE_OID(1248) BKI_SCHEMA_MACRO
{
NameData datname; /* database name */
Oid datdba; /* owner of database */
int4 encoding; /* character encoding */
NameData datcollate; /* LC_COLLATE setting */
NameData datctype; /* LC_CTYPE setting */
bool datistemplate; /* allowed as CREATE DATABASE template? */
bool datallowconn; /* new connections allowed? */
int4 datconnlimit; /* max connections allowed (-1=no limit) */
Oid datlastsysoid; /* highest OID to consider a system OID */
TransactionId datfrozenxid; /* all Xids < this are frozen in this DB */
Oid dattablespace; /* default table space for this DB */
aclitem datacl[1]; /* access permissions (VAR LENGTH) */
} FormData_pg_database;
/* ----------------
* Form_pg_database corresponds to a pointer to a tuple with
* the format of pg_database relation.
* ----------------
*/
typedef FormData_pg_database *Form_pg_database;
/* ----------------
* compiler constants for pg_database
* ----------------
*/
#define Natts_pg_database 12
#define Anum_pg_database_datname 1
#define Anum_pg_database_datdba 2
#define Anum_pg_database_encoding 3
#define Anum_pg_database_datcollate 4
#define Anum_pg_database_datctype 5
#define Anum_pg_database_datistemplate 6
#define Anum_pg_database_datallowconn 7
#define Anum_pg_database_datconnlimit 8
#define Anum_pg_database_datlastsysoid 9
#define Anum_pg_database_datfrozenxid 10
#define Anum_pg_database_dattablespace 11
#define Anum_pg_database_datacl 12
DATA(insert OID = 1 ( template1 PGUID ENCODING "LC_COLLATE" "LC_CTYPE" t t -1 0 0 1663 _null_));
SHDESCR("default template for new databases");
#define TemplateDbOid 1
#endif /* PG_DATABASE_H */

View file

@ -0,0 +1,67 @@
/*-------------------------------------------------------------------------
*
* pg_db_role_setting.h
* definition of configuration settings
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_db_role_setting.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_DB_ROLE_SETTING_H
#define PG_DB_ROLE_SETTING_H
#include "catalog/genbki.h"
#include "nodes/parsenodes.h"
#include "utils/guc.h"
#include "utils/relcache.h"
/* ----------------
* pg_db_role_setting definition. cpp turns this into
* typedef struct FormData_pg_db_role_setting
* ----------------
*/
#define DbRoleSettingRelationId 2964
CATALOG(pg_db_role_setting,2964) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
{
Oid setdatabase; /* database */
Oid setrole; /* role */
text setconfig[1]; /* GUC settings to apply at login */
} FormData_pg_db_role_setting;
typedef FormData_pg_db_role_setting *Form_pg_db_role_setting;
/* ----------------
* compiler constants for pg_db_role_setting
* ----------------
*/
#define Natts_pg_db_role_setting 3
#define Anum_pg_db_role_setting_setdatabase 1
#define Anum_pg_db_role_setting_setrole 2
#define Anum_pg_db_role_setting_setconfig 3
/* ----------------
* initial contents of pg_db_role_setting are NOTHING
* ----------------
*/
/*
* prototypes for functions in pg_db_role_setting.h
*/
extern void AlterSetting(Oid databaseid, Oid roleid, VariableSetStmt *setstmt);
extern void DropSetting(Oid databaseid, Oid roleid);
extern void ApplySetting(Oid databaseid, Oid roleid, Relation relsetting,
GucSource source);
#endif /* PG_DB_ROLE_SETTING_H */

View file

@ -0,0 +1,75 @@
/*-------------------------------------------------------------------------
*
* pg_default_acl.h
* definition of default ACLs for new objects.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_default_acl.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_DEFAULT_ACL_H
#define PG_DEFAULT_ACL_H
#include "catalog/genbki.h"
/* ----------------
* pg_default_acl definition. cpp turns this into
* typedef struct FormData_pg_default_acl
* ----------------
*/
#define DefaultAclRelationId 826
CATALOG(pg_default_acl,826)
{
Oid defaclrole; /* OID of role owning this ACL */
Oid defaclnamespace; /* OID of namespace, or 0 for all */
char defaclobjtype; /* see DEFACLOBJ_xxx constants below */
/*
* VARIABLE LENGTH FIELDS start here.
*/
aclitem defaclacl[1]; /* permissions to add at CREATE time */
} FormData_pg_default_acl;
/* ----------------
* Form_pg_default_acl corresponds to a pointer to a tuple with
* the format of pg_default_acl relation.
* ----------------
*/
typedef FormData_pg_default_acl *Form_pg_default_acl;
/* ----------------
* compiler constants for pg_default_acl
* ----------------
*/
#define Natts_pg_default_acl 4
#define Anum_pg_default_acl_defaclrole 1
#define Anum_pg_default_acl_defaclnamespace 2
#define Anum_pg_default_acl_defaclobjtype 3
#define Anum_pg_default_acl_defaclacl 4
/* ----------------
* pg_default_acl has no initial contents
* ----------------
*/
/*
* Types of objects for which the user is allowed to specify default
* permissions through pg_default_acl. These codes are used in the
* defaclobjtype column.
*/
#define DEFACLOBJ_RELATION 'r' /* table, view */
#define DEFACLOBJ_SEQUENCE 'S' /* sequence */
#define DEFACLOBJ_FUNCTION 'f' /* function */
#endif /* PG_DEFAULT_ACL_H */

90
deps/libpq/include/catalog/pg_depend.h vendored Normal file
View file

@ -0,0 +1,90 @@
/*-------------------------------------------------------------------------
*
* pg_depend.h
* definition of the system "dependency" relation (pg_depend)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_depend.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_DEPEND_H
#define PG_DEPEND_H
#include "catalog/genbki.h"
/* ----------------
* pg_depend definition. cpp turns this into
* typedef struct FormData_pg_depend
* ----------------
*/
#define DependRelationId 2608
CATALOG(pg_depend,2608) BKI_WITHOUT_OIDS
{
/*
* Identification of the dependent (referencing) object.
*
* These fields are all zeroes for a DEPENDENCY_PIN entry.
*/
Oid classid; /* OID of table containing object */
Oid objid; /* OID of object itself */
int4 objsubid; /* column number, or 0 if not used */
/*
* Identification of the independent (referenced) object.
*/
Oid refclassid; /* OID of table containing object */
Oid refobjid; /* OID of object itself */
int4 refobjsubid; /* column number, or 0 if not used */
/*
* Precise semantics of the relationship are specified by the deptype
* field. See DependencyType in catalog/dependency.h.
*/
char deptype; /* see codes in dependency.h */
} FormData_pg_depend;
/* ----------------
* Form_pg_depend corresponds to a pointer to a row with
* the format of pg_depend relation.
* ----------------
*/
typedef FormData_pg_depend *Form_pg_depend;
/* ----------------
* compiler constants for pg_depend
* ----------------
*/
#define Natts_pg_depend 7
#define Anum_pg_depend_classid 1
#define Anum_pg_depend_objid 2
#define Anum_pg_depend_objsubid 3
#define Anum_pg_depend_refclassid 4
#define Anum_pg_depend_refobjid 5
#define Anum_pg_depend_refobjsubid 6
#define Anum_pg_depend_deptype 7
/*
* pg_depend has no preloaded contents; system-defined dependencies are
* loaded into it during a late stage of the initdb process.
*
* NOTE: we do not represent all possible dependency pairs in pg_depend;
* for example, there's not much value in creating an explicit dependency
* from an attribute to its relation. Usually we make a dependency for
* cases where the relationship is conditional rather than essential
* (for example, not all triggers are dependent on constraints, but all
* attributes are dependent on relations) or where the dependency is not
* convenient to find from the contents of other catalogs.
*/
#endif /* PG_DEPEND_H */

View file

@ -0,0 +1,84 @@
/*-------------------------------------------------------------------------
*
* pg_description.h
* definition of the system "description" relation (pg_description)
*
* NOTE: an object is identified by the OID of the row that primarily
* defines the object, plus the OID of the table that that row appears in.
* For example, a function is identified by the OID of its pg_proc row
* plus the pg_class OID of table pg_proc. This allows unique identification
* of objects without assuming that OIDs are unique across tables.
*
* Since attributes don't have OIDs of their own, we identify an attribute
* comment by the objoid+classoid of its parent table, plus an "objsubid"
* giving the attribute column number. "objsubid" must be zero in a comment
* for a table itself, so that it is distinct from any column comment.
* Currently, objsubid is unused and zero for all other kinds of objects,
* but perhaps it might be useful someday to associate comments with
* constituent elements of other kinds of objects (arguments of a function,
* for example).
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_description.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_DESCRIPTION_H
#define PG_DESCRIPTION_H
#include "catalog/genbki.h"
/* ----------------
* pg_description definition. cpp turns this into
* typedef struct FormData_pg_description
* ----------------
*/
#define DescriptionRelationId 2609
CATALOG(pg_description,2609) BKI_WITHOUT_OIDS
{
Oid objoid; /* OID of object itself */
Oid classoid; /* OID of table containing object */
int4 objsubid; /* column number, or 0 if not used */
text description; /* description of object */
} FormData_pg_description;
/* ----------------
* Form_pg_description corresponds to a pointer to a tuple with
* the format of pg_description relation.
* ----------------
*/
typedef FormData_pg_description *Form_pg_description;
/* ----------------
* compiler constants for pg_description
* ----------------
*/
#define Natts_pg_description 4
#define Anum_pg_description_objoid 1
#define Anum_pg_description_classoid 2
#define Anum_pg_description_objsubid 3
#define Anum_pg_description_description 4
/* ----------------
* initial contents of pg_description
* ----------------
*/
/*
* Because the contents of this table are taken from the other *.h files,
* there is no initialization here. The initial contents are extracted
* by genbki.pl and loaded during initdb.
*/
#endif /* PG_DESCRIPTION_H */

70
deps/libpq/include/catalog/pg_enum.h vendored Normal file
View file

@ -0,0 +1,70 @@
/*-------------------------------------------------------------------------
*
* pg_enum.h
* definition of the system "enum" relation (pg_enum)
* along with the relation's initial contents.
*
*
* Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* src/include/catalog/pg_enum.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_ENUM_H
#define PG_ENUM_H
#include "catalog/genbki.h"
#include "nodes/pg_list.h"
/* ----------------
* pg_enum definition. cpp turns this into
* typedef struct FormData_pg_enum
* ----------------
*/
#define EnumRelationId 3501
CATALOG(pg_enum,3501)
{
Oid enumtypid; /* OID of owning enum type */
float4 enumsortorder; /* sort position of this enum value */
NameData enumlabel; /* text representation of enum value */
} FormData_pg_enum;
/* ----------------
* Form_pg_enum corresponds to a pointer to a tuple with
* the format of pg_enum relation.
* ----------------
*/
typedef FormData_pg_enum *Form_pg_enum;
/* ----------------
* compiler constants for pg_enum
* ----------------
*/
#define Natts_pg_enum 3
#define Anum_pg_enum_enumtypid 1
#define Anum_pg_enum_enumsortorder 2
#define Anum_pg_enum_enumlabel 3
/* ----------------
* pg_enum has no initial contents
* ----------------
*/
/*
* prototypes for functions in pg_enum.c
*/
extern void EnumValuesCreate(Oid enumTypeOid, List *vals);
extern void EnumValuesDelete(Oid enumTypeOid);
extern void AddEnumLabel(Oid enumTypeOid, const char *newVal,
const char *neighbor, bool newValIsAfter);
#endif /* PG_ENUM_H */

View file

@ -0,0 +1,74 @@
/*-------------------------------------------------------------------------
*
* pg_extension.h
* definition of the system "extension" relation (pg_extension)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_extension.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_EXTENSION_H
#define PG_EXTENSION_H
#include "catalog/genbki.h"
/* ----------------
* pg_extension definition. cpp turns this into
* typedef struct FormData_pg_extension
* ----------------
*/
#define ExtensionRelationId 3079
CATALOG(pg_extension,3079)
{
NameData extname; /* extension name */
Oid extowner; /* extension owner */
Oid extnamespace; /* namespace of contained objects */
bool extrelocatable; /* if true, allow ALTER EXTENSION SET SCHEMA */
/*
* VARIABLE LENGTH FIELDS start here.
*
* extversion should never be null, but the others can be.
*/
text extversion; /* extension version name */
Oid extconfig[1]; /* dumpable configuration tables */
text extcondition[1]; /* WHERE clauses for config tables */
} FormData_pg_extension;
/* ----------------
* Form_pg_extension corresponds to a pointer to a tuple with
* the format of pg_extension relation.
* ----------------
*/
typedef FormData_pg_extension *Form_pg_extension;
/* ----------------
* compiler constants for pg_extension
* ----------------
*/
#define Natts_pg_extension 7
#define Anum_pg_extension_extname 1
#define Anum_pg_extension_extowner 2
#define Anum_pg_extension_extnamespace 3
#define Anum_pg_extension_extrelocatable 4
#define Anum_pg_extension_extversion 5
#define Anum_pg_extension_extconfig 6
#define Anum_pg_extension_extcondition 7
/* ----------------
* pg_extension has no initial contents
* ----------------
*/
#endif /* PG_EXTENSION_H */

View file

@ -0,0 +1,64 @@
/*-------------------------------------------------------------------------
*
* pg_foreign_data_wrapper.h
* definition of the system "foreign-data wrapper" relation (pg_foreign_data_wrapper)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_foreign_data_wrapper.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_FOREIGN_DATA_WRAPPER_H
#define PG_FOREIGN_DATA_WRAPPER_H
#include "catalog/genbki.h"
/* ----------------
* pg_foreign_data_wrapper definition. cpp turns this into
* typedef struct FormData_pg_foreign_data_wrapper
* ----------------
*/
#define ForeignDataWrapperRelationId 2328
CATALOG(pg_foreign_data_wrapper,2328)
{
NameData fdwname; /* foreign-data wrapper name */
Oid fdwowner; /* FDW owner */
Oid fdwhandler; /* handler function, or 0 if none */
Oid fdwvalidator; /* option validation function, or 0 if none */
/* VARIABLE LENGTH FIELDS start here. */
aclitem fdwacl[1]; /* access permissions */
text fdwoptions[1]; /* FDW options */
} FormData_pg_foreign_data_wrapper;
/* ----------------
* Form_pg_fdw corresponds to a pointer to a tuple with
* the format of pg_fdw relation.
* ----------------
*/
typedef FormData_pg_foreign_data_wrapper *Form_pg_foreign_data_wrapper;
/* ----------------
* compiler constants for pg_fdw
* ----------------
*/
#define Natts_pg_foreign_data_wrapper 6
#define Anum_pg_foreign_data_wrapper_fdwname 1
#define Anum_pg_foreign_data_wrapper_fdwowner 2
#define Anum_pg_foreign_data_wrapper_fdwhandler 3
#define Anum_pg_foreign_data_wrapper_fdwvalidator 4
#define Anum_pg_foreign_data_wrapper_fdwacl 5
#define Anum_pg_foreign_data_wrapper_fdwoptions 6
#endif /* PG_FOREIGN_DATA_WRAPPER_H */

View file

@ -0,0 +1,65 @@
/*-------------------------------------------------------------------------
*
* pg_foreign_server.h
* definition of the system "foreign server" relation (pg_foreign_server)
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_foreign_server.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_FOREIGN_SERVER_H
#define PG_FOREIGN_SERVER_H
#include "catalog/genbki.h"
/* ----------------
* pg_foreign_server definition. cpp turns this into
* typedef struct FormData_pg_foreign_server
* ----------------
*/
#define ForeignServerRelationId 1417
CATALOG(pg_foreign_server,1417)
{
NameData srvname; /* foreign server name */
Oid srvowner; /* server owner */
Oid srvfdw; /* server FDW */
/*
* VARIABLE LENGTH FIELDS start here. These fields may be NULL, too.
*/
text srvtype;
text srvversion;
aclitem srvacl[1]; /* access permissions */
text srvoptions[1]; /* FDW-specific options */
} FormData_pg_foreign_server;
/* ----------------
* Form_pg_foreign_server corresponds to a pointer to a tuple with
* the format of pg_foreign_server relation.
* ----------------
*/
typedef FormData_pg_foreign_server *Form_pg_foreign_server;
/* ----------------
* compiler constants for pg_foreign_server
* ----------------
*/
#define Natts_pg_foreign_server 7
#define Anum_pg_foreign_server_srvname 1
#define Anum_pg_foreign_server_srvowner 2
#define Anum_pg_foreign_server_srvfdw 3
#define Anum_pg_foreign_server_srvtype 4
#define Anum_pg_foreign_server_srvversion 5
#define Anum_pg_foreign_server_srvacl 6
#define Anum_pg_foreign_server_srvoptions 7
#endif /* PG_FOREIGN_SERVER_H */

View file

@ -0,0 +1,53 @@
/*-------------------------------------------------------------------------
*
* pg_foreign_table.h
* definition of the system "foreign table" relation (pg_foreign_table)
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_foreign_table.h
*
* NOTES
* the genbki.sh script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_FOREIGN_TABLE_H
#define PG_FOREIGN_TABLE_H
#include "catalog/genbki.h"
/* ----------------
* pg_foreign_table definition. cpp turns this into
* typedef struct FormData_pg_foreign_table
* ----------------
*/
#define ForeignTableRelationId 3118
CATALOG(pg_foreign_table,3118) BKI_WITHOUT_OIDS
{
Oid ftrelid; /* OID of foreign table */
Oid ftserver; /* OID of foreign server */
text ftoptions[1]; /* FDW-specific options */
} FormData_pg_foreign_table;
/* ----------------
* Form_pg_foreign_table corresponds to a pointer to a tuple with
* the format of pg_foreign_table relation.
* ----------------
*/
typedef FormData_pg_foreign_table *Form_pg_foreign_table;
/* ----------------
* compiler constants for pg_foreign_table
* ----------------
*/
#define Natts_pg_foreign_table 3
#define Anum_pg_foreign_table_ftrelid 1
#define Anum_pg_foreign_table_ftserver 2
#define Anum_pg_foreign_table_ftoptions 3
#endif /* PG_FOREIGN_TABLE_H */

95
deps/libpq/include/catalog/pg_index.h vendored Normal file
View file

@ -0,0 +1,95 @@
/*-------------------------------------------------------------------------
*
* pg_index.h
* definition of the system "index" relation (pg_index)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_index.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_INDEX_H
#define PG_INDEX_H
#include "catalog/genbki.h"
/* ----------------
* pg_index definition. cpp turns this into
* typedef struct FormData_pg_index.
* ----------------
*/
#define IndexRelationId 2610
CATALOG(pg_index,2610) BKI_WITHOUT_OIDS BKI_SCHEMA_MACRO
{
Oid indexrelid; /* OID of the index */
Oid indrelid; /* OID of the relation it indexes */
int2 indnatts; /* number of columns in index */
bool indisunique; /* is this a unique index? */
bool indisprimary; /* is this index for primary key? */
bool indisexclusion; /* is this index for exclusion constraint? */
bool indimmediate; /* is uniqueness enforced immediately? */
bool indisclustered; /* is this the index last clustered by? */
bool indisvalid; /* is this index valid for use by queries? */
bool indcheckxmin; /* must we wait for xmin to be old? */
bool indisready; /* is this index ready for inserts? */
/* VARIABLE LENGTH FIELDS: */
int2vector indkey; /* column numbers of indexed cols, or 0 */
oidvector indcollation; /* collation identifiers */
oidvector indclass; /* opclass identifiers */
int2vector indoption; /* per-column flags (AM-specific meanings) */
pg_node_tree indexprs; /* expression trees for index attributes that
* are not simple column references; one for
* each zero entry in indkey[] */
pg_node_tree indpred; /* expression tree for predicate, if a partial
* index; else NULL */
} FormData_pg_index;
/* ----------------
* Form_pg_index corresponds to a pointer to a tuple with
* the format of pg_index relation.
* ----------------
*/
typedef FormData_pg_index *Form_pg_index;
/* ----------------
* compiler constants for pg_index
* ----------------
*/
#define Natts_pg_index 17
#define Anum_pg_index_indexrelid 1
#define Anum_pg_index_indrelid 2
#define Anum_pg_index_indnatts 3
#define Anum_pg_index_indisunique 4
#define Anum_pg_index_indisprimary 5
#define Anum_pg_index_indisexclusion 6
#define Anum_pg_index_indimmediate 7
#define Anum_pg_index_indisclustered 8
#define Anum_pg_index_indisvalid 9
#define Anum_pg_index_indcheckxmin 10
#define Anum_pg_index_indisready 11
#define Anum_pg_index_indkey 12
#define Anum_pg_index_indcollation 13
#define Anum_pg_index_indclass 14
#define Anum_pg_index_indoption 15
#define Anum_pg_index_indexprs 16
#define Anum_pg_index_indpred 17
/*
* Index AMs that support ordered scans must support these two indoption
* bits. Otherwise, the content of the per-column indoption fields is
* open for future definition.
*/
#define INDOPTION_DESC 0x0001 /* values are in reverse order */
#define INDOPTION_NULLS_FIRST 0x0002 /* NULLs are first instead of last */
#endif /* PG_INDEX_H */

View file

@ -0,0 +1,59 @@
/*-------------------------------------------------------------------------
*
* pg_inherits.h
* definition of the system "inherits" relation (pg_inherits)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_inherits.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_INHERITS_H
#define PG_INHERITS_H
#include "catalog/genbki.h"
/* ----------------
* pg_inherits definition. cpp turns this into
* typedef struct FormData_pg_inherits
* ----------------
*/
#define InheritsRelationId 2611
CATALOG(pg_inherits,2611) BKI_WITHOUT_OIDS
{
Oid inhrelid;
Oid inhparent;
int4 inhseqno;
} FormData_pg_inherits;
/* ----------------
* Form_pg_inherits corresponds to a pointer to a tuple with
* the format of pg_inherits relation.
* ----------------
*/
typedef FormData_pg_inherits *Form_pg_inherits;
/* ----------------
* compiler constants for pg_inherits
* ----------------
*/
#define Natts_pg_inherits 3
#define Anum_pg_inherits_inhrelid 1
#define Anum_pg_inherits_inhparent 2
#define Anum_pg_inherits_inhseqno 3
/* ----------------
* pg_inherits has no initial contents
* ----------------
*/
#endif /* PG_INHERITS_H */

View file

@ -0,0 +1,26 @@
/*-------------------------------------------------------------------------
*
* pg_inherits_fn.h
* prototypes for functions in catalog/pg_inherits.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_inherits_fn.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_INHERITS_FN_H
#define PG_INHERITS_FN_H
#include "nodes/pg_list.h"
#include "storage/lock.h"
extern List *find_inheritance_children(Oid parentrelId, LOCKMODE lockmode);
extern List *find_all_inheritors(Oid parentrelId, LOCKMODE lockmode,
List **parents);
extern bool has_subclass(Oid relationId);
extern bool typeInheritsFrom(Oid subclassTypeId, Oid superclassTypeId);
#endif /* PG_INHERITS_FN_H */

View file

@ -0,0 +1,79 @@
/*-------------------------------------------------------------------------
*
* pg_language.h
* definition of the system "language" relation (pg_language)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_language.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_LANGUAGE_H
#define PG_LANGUAGE_H
#include "catalog/genbki.h"
/* ----------------
* pg_language definition. cpp turns this into
* typedef struct FormData_pg_language
* ----------------
*/
#define LanguageRelationId 2612
CATALOG(pg_language,2612)
{
NameData lanname; /* Language name */
Oid lanowner; /* Language's owner */
bool lanispl; /* Is a procedural language */
bool lanpltrusted; /* PL is trusted */
Oid lanplcallfoid; /* Call handler for PL */
Oid laninline; /* Optional anonymous-block handler function */
Oid lanvalidator; /* Optional validation function */
aclitem lanacl[1]; /* Access privileges */
} FormData_pg_language;
/* ----------------
* Form_pg_language corresponds to a pointer to a tuple with
* the format of pg_language relation.
* ----------------
*/
typedef FormData_pg_language *Form_pg_language;
/* ----------------
* compiler constants for pg_language
* ----------------
*/
#define Natts_pg_language 8
#define Anum_pg_language_lanname 1
#define Anum_pg_language_lanowner 2
#define Anum_pg_language_lanispl 3
#define Anum_pg_language_lanpltrusted 4
#define Anum_pg_language_lanplcallfoid 5
#define Anum_pg_language_laninline 6
#define Anum_pg_language_lanvalidator 7
#define Anum_pg_language_lanacl 8
/* ----------------
* initial contents of pg_language
* ----------------
*/
DATA(insert OID = 12 ( "internal" PGUID f f 0 0 2246 _null_ ));
DESCR("built-in functions");
#define INTERNALlanguageId 12
DATA(insert OID = 13 ( "c" PGUID f f 0 0 2247 _null_ ));
DESCR("dynamically-loaded C functions");
#define ClanguageId 13
DATA(insert OID = 14 ( "sql" PGUID f t 0 0 2248 _null_ ));
DESCR("SQL-language functions");
#define SQLlanguageId 14
#endif /* PG_LANGUAGE_H */

View file

@ -0,0 +1,59 @@
/*-------------------------------------------------------------------------
*
* pg_largeobject.h
* definition of the system "largeobject" relation (pg_largeobject)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_largeobject.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_LARGEOBJECT_H
#define PG_LARGEOBJECT_H
#include "catalog/genbki.h"
/* ----------------
* pg_largeobject definition. cpp turns this into
* typedef struct FormData_pg_largeobject
* ----------------
*/
#define LargeObjectRelationId 2613
CATALOG(pg_largeobject,2613) BKI_WITHOUT_OIDS
{
Oid loid; /* Identifier of large object */
int4 pageno; /* Page number (starting from 0) */
bytea data; /* Data for page (may be zero-length) */
} FormData_pg_largeobject;
/* ----------------
* Form_pg_largeobject corresponds to a pointer to a tuple with
* the format of pg_largeobject relation.
* ----------------
*/
typedef FormData_pg_largeobject *Form_pg_largeobject;
/* ----------------
* compiler constants for pg_largeobject
* ----------------
*/
#define Natts_pg_largeobject 3
#define Anum_pg_largeobject_loid 1
#define Anum_pg_largeobject_pageno 2
#define Anum_pg_largeobject_data 3
extern Oid LargeObjectCreate(Oid loid);
extern void LargeObjectDrop(Oid loid);
extern void LargeObjectAlterOwner(Oid loid, Oid newOwnerId);
extern bool LargeObjectExists(Oid loid);
#endif /* PG_LARGEOBJECT_H */

View file

@ -0,0 +1,52 @@
/*-------------------------------------------------------------------------
*
* pg_largeobject_metadata.h
* definition of the system "largeobject_metadata" relation (pg_largeobject_metadata)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_largeobject_metadata.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_LARGEOBJECT_METADATA_H
#define PG_LARGEOBJECT_METADATA_H
#include "catalog/genbki.h"
/* ----------------
* pg_largeobject_metadata definition. cpp turns this into
* typedef struct FormData_pg_largeobject_metadata
* ----------------
*/
#define LargeObjectMetadataRelationId 2995
CATALOG(pg_largeobject_metadata,2995)
{
Oid lomowner; /* OID of the largeobject owner */
aclitem lomacl[1]; /* access permissions */
} FormData_pg_largeobject_metadata;
/* ----------------
* Form_pg_largeobject_metadata corresponds to a pointer to a tuple
* with the format of pg_largeobject_metadata relation.
* ----------------
*/
typedef FormData_pg_largeobject_metadata *Form_pg_largeobject_metadata;
/* ----------------
* compiler constants for pg_largeobject_metadata
* ----------------
*/
#define Natts_pg_largeobject_metadata 2
#define Anum_pg_largeobject_metadata_lomowner 1
#define Anum_pg_largeobject_metadata_lomacl 2
#endif /* PG_LARGEOBJECT_METADATA_H */

View file

@ -0,0 +1,82 @@
/*-------------------------------------------------------------------------
*
* pg_namespace.h
* definition of the system "namespace" relation (pg_namespace)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_namespace.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_NAMESPACE_H
#define PG_NAMESPACE_H
#include "catalog/genbki.h"
/* ----------------------------------------------------------------
* pg_namespace definition.
*
* cpp turns this into typedef struct FormData_pg_namespace
*
* nspname name of the namespace
* nspowner owner (creator) of the namespace
* nspacl access privilege list
* ----------------------------------------------------------------
*/
#define NamespaceRelationId 2615
CATALOG(pg_namespace,2615)
{
NameData nspname;
Oid nspowner;
aclitem nspacl[1]; /* VARIABLE LENGTH FIELD */
} FormData_pg_namespace;
/* ----------------
* Form_pg_namespace corresponds to a pointer to a tuple with
* the format of pg_namespace relation.
* ----------------
*/
typedef FormData_pg_namespace *Form_pg_namespace;
/* ----------------
* compiler constants for pg_namespace
* ----------------
*/
#define Natts_pg_namespace 3
#define Anum_pg_namespace_nspname 1
#define Anum_pg_namespace_nspowner 2
#define Anum_pg_namespace_nspacl 3
/* ----------------
* initial contents of pg_namespace
* ---------------
*/
DATA(insert OID = 11 ( "pg_catalog" PGUID _null_ ));
DESCR("system catalog schema");
#define PG_CATALOG_NAMESPACE 11
DATA(insert OID = 99 ( "pg_toast" PGUID _null_ ));
DESCR("reserved schema for TOAST tables");
#define PG_TOAST_NAMESPACE 99
DATA(insert OID = 2200 ( "public" PGUID _null_ ));
DESCR("standard public schema");
#define PG_PUBLIC_NAMESPACE 2200
/*
* prototypes for functions in pg_namespace.c
*/
extern Oid NamespaceCreate(const char *nspName, Oid ownerId, bool isTemp);
#endif /* PG_NAMESPACE_H */

217
deps/libpq/include/catalog/pg_opclass.h vendored Normal file
View file

@ -0,0 +1,217 @@
/*-------------------------------------------------------------------------
*
* pg_opclass.h
* definition of the system "opclass" relation (pg_opclass)
* along with the relation's initial contents.
*
* The primary key for this table is <opcmethod, opcname, opcnamespace> ---
* that is, there is a row for each valid combination of opclass name and
* index access method type. This row specifies the expected input data type
* for the opclass (the type of the heap column, or the expression output type
* in the case of an index expression). Note that types binary-coercible to
* the specified type will be accepted too.
*
* For a given <opcmethod, opcintype> pair, there can be at most one row that
* has opcdefault = true; this row is the default opclass for such data in
* such an index. (This is not currently enforced by an index, because we
* don't support partial indexes on system catalogs.)
*
* Normally opckeytype = InvalidOid (zero), indicating that the data stored
* in the index is the same as the data in the indexed column. If opckeytype
* is nonzero then it indicates that a conversion step is needed to produce
* the stored index data, which will be of type opckeytype (which might be
* the same or different from the input datatype). Performing such a
* conversion is the responsibility of the index access method --- not all
* AMs support this.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_opclass.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_OPCLASS_H
#define PG_OPCLASS_H
#include "catalog/genbki.h"
/* ----------------
* pg_opclass definition. cpp turns this into
* typedef struct FormData_pg_opclass
* ----------------
*/
#define OperatorClassRelationId 2616
CATALOG(pg_opclass,2616)
{
Oid opcmethod; /* index access method opclass is for */
NameData opcname; /* name of this opclass */
Oid opcnamespace; /* namespace of this opclass */
Oid opcowner; /* opclass owner */
Oid opcfamily; /* containing operator family */
Oid opcintype; /* type of data indexed by opclass */
bool opcdefault; /* T if opclass is default for opcintype */
Oid opckeytype; /* type of data in index, or InvalidOid */
} FormData_pg_opclass;
/* ----------------
* Form_pg_opclass corresponds to a pointer to a tuple with
* the format of pg_opclass relation.
* ----------------
*/
typedef FormData_pg_opclass *Form_pg_opclass;
/* ----------------
* compiler constants for pg_opclass
* ----------------
*/
#define Natts_pg_opclass 8
#define Anum_pg_opclass_opcmethod 1
#define Anum_pg_opclass_opcname 2
#define Anum_pg_opclass_opcnamespace 3
#define Anum_pg_opclass_opcowner 4
#define Anum_pg_opclass_opcfamily 5
#define Anum_pg_opclass_opcintype 6
#define Anum_pg_opclass_opcdefault 7
#define Anum_pg_opclass_opckeytype 8
/* ----------------
* initial contents of pg_opclass
*
* Note: we hard-wire an OID only for a few entries that have to be explicitly
* referenced in the C code for bootstrapping purposes. The rest get OIDs
* assigned on-the-fly during initdb.
* ----------------
*/
DATA(insert ( 403 abstime_ops PGNSP PGUID 421 702 t 0 ));
DATA(insert ( 403 array_ops PGNSP PGUID 397 2277 t 0 ));
DATA(insert ( 405 array_ops PGNSP PGUID 627 2277 t 0 ));
DATA(insert ( 403 bit_ops PGNSP PGUID 423 1560 t 0 ));
DATA(insert ( 403 bool_ops PGNSP PGUID 424 16 t 0 ));
DATA(insert ( 403 bpchar_ops PGNSP PGUID 426 1042 t 0 ));
DATA(insert ( 405 bpchar_ops PGNSP PGUID 427 1042 t 0 ));
DATA(insert ( 403 bytea_ops PGNSP PGUID 428 17 t 0 ));
DATA(insert ( 403 char_ops PGNSP PGUID 429 18 t 0 ));
DATA(insert ( 405 char_ops PGNSP PGUID 431 18 t 0 ));
DATA(insert ( 403 cidr_ops PGNSP PGUID 1974 869 f 0 ));
DATA(insert ( 405 cidr_ops PGNSP PGUID 1975 869 f 0 ));
DATA(insert ( 403 date_ops PGNSP PGUID 434 1082 t 0 ));
DATA(insert ( 405 date_ops PGNSP PGUID 435 1082 t 0 ));
DATA(insert ( 403 float4_ops PGNSP PGUID 1970 700 t 0 ));
DATA(insert ( 405 float4_ops PGNSP PGUID 1971 700 t 0 ));
DATA(insert ( 403 float8_ops PGNSP PGUID 1970 701 t 0 ));
DATA(insert ( 405 float8_ops PGNSP PGUID 1971 701 t 0 ));
DATA(insert ( 403 inet_ops PGNSP PGUID 1974 869 t 0 ));
DATA(insert ( 405 inet_ops PGNSP PGUID 1975 869 t 0 ));
DATA(insert OID = 1979 ( 403 int2_ops PGNSP PGUID 1976 21 t 0 ));
#define INT2_BTREE_OPS_OID 1979
DATA(insert ( 405 int2_ops PGNSP PGUID 1977 21 t 0 ));
DATA(insert OID = 1978 ( 403 int4_ops PGNSP PGUID 1976 23 t 0 ));
#define INT4_BTREE_OPS_OID 1978
DATA(insert ( 405 int4_ops PGNSP PGUID 1977 23 t 0 ));
DATA(insert ( 403 int8_ops PGNSP PGUID 1976 20 t 0 ));
DATA(insert ( 405 int8_ops PGNSP PGUID 1977 20 t 0 ));
DATA(insert ( 403 interval_ops PGNSP PGUID 1982 1186 t 0 ));
DATA(insert ( 405 interval_ops PGNSP PGUID 1983 1186 t 0 ));
DATA(insert ( 403 macaddr_ops PGNSP PGUID 1984 829 t 0 ));
DATA(insert ( 405 macaddr_ops PGNSP PGUID 1985 829 t 0 ));
/*
* Here's an ugly little hack to save space in the system catalog indexes.
* btree doesn't ordinarily allow a storage type different from input type;
* but cstring and name are the same thing except for trailing padding,
* and we can safely omit that within an index entry. So we declare the
* btree opclass for name as using cstring storage type.
*/
DATA(insert ( 403 name_ops PGNSP PGUID 1986 19 t 2275 ));
DATA(insert ( 405 name_ops PGNSP PGUID 1987 19 t 0 ));
DATA(insert ( 403 numeric_ops PGNSP PGUID 1988 1700 t 0 ));
DATA(insert ( 405 numeric_ops PGNSP PGUID 1998 1700 t 0 ));
DATA(insert OID = 1981 ( 403 oid_ops PGNSP PGUID 1989 26 t 0 ));
#define OID_BTREE_OPS_OID 1981
DATA(insert ( 405 oid_ops PGNSP PGUID 1990 26 t 0 ));
DATA(insert ( 403 oidvector_ops PGNSP PGUID 1991 30 t 0 ));
DATA(insert ( 405 oidvector_ops PGNSP PGUID 1992 30 t 0 ));
DATA(insert ( 403 record_ops PGNSP PGUID 2994 2249 t 0 ));
DATA(insert ( 403 text_ops PGNSP PGUID 1994 25 t 0 ));
DATA(insert ( 405 text_ops PGNSP PGUID 1995 25 t 0 ));
DATA(insert ( 403 time_ops PGNSP PGUID 1996 1083 t 0 ));
DATA(insert ( 405 time_ops PGNSP PGUID 1997 1083 t 0 ));
DATA(insert ( 403 timestamptz_ops PGNSP PGUID 434 1184 t 0 ));
DATA(insert ( 405 timestamptz_ops PGNSP PGUID 1999 1184 t 0 ));
DATA(insert ( 403 timetz_ops PGNSP PGUID 2000 1266 t 0 ));
DATA(insert ( 405 timetz_ops PGNSP PGUID 2001 1266 t 0 ));
DATA(insert ( 403 varbit_ops PGNSP PGUID 2002 1562 t 0 ));
DATA(insert ( 403 varchar_ops PGNSP PGUID 1994 25 f 0 ));
DATA(insert ( 405 varchar_ops PGNSP PGUID 1995 25 f 0 ));
DATA(insert ( 403 timestamp_ops PGNSP PGUID 434 1114 t 0 ));
DATA(insert ( 405 timestamp_ops PGNSP PGUID 2040 1114 t 0 ));
DATA(insert ( 403 text_pattern_ops PGNSP PGUID 2095 25 f 0 ));
DATA(insert ( 403 varchar_pattern_ops PGNSP PGUID 2095 25 f 0 ));
DATA(insert ( 403 bpchar_pattern_ops PGNSP PGUID 2097 1042 f 0 ));
DATA(insert ( 403 money_ops PGNSP PGUID 2099 790 t 0 ));
DATA(insert ( 405 bool_ops PGNSP PGUID 2222 16 t 0 ));
DATA(insert ( 405 bytea_ops PGNSP PGUID 2223 17 t 0 ));
DATA(insert ( 405 int2vector_ops PGNSP PGUID 2224 22 t 0 ));
DATA(insert ( 403 tid_ops PGNSP PGUID 2789 27 t 0 ));
DATA(insert ( 405 xid_ops PGNSP PGUID 2225 28 t 0 ));
DATA(insert ( 405 cid_ops PGNSP PGUID 2226 29 t 0 ));
DATA(insert ( 405 abstime_ops PGNSP PGUID 2227 702 t 0 ));
DATA(insert ( 405 reltime_ops PGNSP PGUID 2228 703 t 0 ));
DATA(insert ( 405 text_pattern_ops PGNSP PGUID 2229 25 f 0 ));
DATA(insert ( 405 varchar_pattern_ops PGNSP PGUID 2229 25 f 0 ));
DATA(insert ( 405 bpchar_pattern_ops PGNSP PGUID 2231 1042 f 0 ));
DATA(insert ( 403 reltime_ops PGNSP PGUID 2233 703 t 0 ));
DATA(insert ( 403 tinterval_ops PGNSP PGUID 2234 704 t 0 ));
DATA(insert ( 405 aclitem_ops PGNSP PGUID 2235 1033 t 0 ));
DATA(insert ( 783 box_ops PGNSP PGUID 2593 603 t 0 ));
DATA(insert ( 783 point_ops PGNSP PGUID 1029 600 t 603 ));
DATA(insert ( 783 poly_ops PGNSP PGUID 2594 604 t 603 ));
DATA(insert ( 783 circle_ops PGNSP PGUID 2595 718 t 603 ));
DATA(insert ( 2742 _int4_ops PGNSP PGUID 2745 1007 t 23 ));
DATA(insert ( 2742 _text_ops PGNSP PGUID 2745 1009 t 25 ));
DATA(insert ( 2742 _abstime_ops PGNSP PGUID 2745 1023 t 702 ));
DATA(insert ( 2742 _bit_ops PGNSP PGUID 2745 1561 t 1560 ));
DATA(insert ( 2742 _bool_ops PGNSP PGUID 2745 1000 t 16 ));
DATA(insert ( 2742 _bpchar_ops PGNSP PGUID 2745 1014 t 1042 ));
DATA(insert ( 2742 _bytea_ops PGNSP PGUID 2745 1001 t 17 ));
DATA(insert ( 2742 _char_ops PGNSP PGUID 2745 1002 t 18 ));
DATA(insert ( 2742 _cidr_ops PGNSP PGUID 2745 651 t 650 ));
DATA(insert ( 2742 _date_ops PGNSP PGUID 2745 1182 t 1082 ));
DATA(insert ( 2742 _float4_ops PGNSP PGUID 2745 1021 t 700 ));
DATA(insert ( 2742 _float8_ops PGNSP PGUID 2745 1022 t 701 ));
DATA(insert ( 2742 _inet_ops PGNSP PGUID 2745 1041 t 869 ));
DATA(insert ( 2742 _int2_ops PGNSP PGUID 2745 1005 t 21 ));
DATA(insert ( 2742 _int8_ops PGNSP PGUID 2745 1016 t 20 ));
DATA(insert ( 2742 _interval_ops PGNSP PGUID 2745 1187 t 1186 ));
DATA(insert ( 2742 _macaddr_ops PGNSP PGUID 2745 1040 t 829 ));
DATA(insert ( 2742 _name_ops PGNSP PGUID 2745 1003 t 19 ));
DATA(insert ( 2742 _numeric_ops PGNSP PGUID 2745 1231 t 1700 ));
DATA(insert ( 2742 _oid_ops PGNSP PGUID 2745 1028 t 26 ));
DATA(insert ( 2742 _oidvector_ops PGNSP PGUID 2745 1013 t 30 ));
DATA(insert ( 2742 _time_ops PGNSP PGUID 2745 1183 t 1083 ));
DATA(insert ( 2742 _timestamptz_ops PGNSP PGUID 2745 1185 t 1184 ));
DATA(insert ( 2742 _timetz_ops PGNSP PGUID 2745 1270 t 1266 ));
DATA(insert ( 2742 _varbit_ops PGNSP PGUID 2745 1563 t 1562 ));
DATA(insert ( 2742 _varchar_ops PGNSP PGUID 2745 1015 t 1043 ));
DATA(insert ( 2742 _timestamp_ops PGNSP PGUID 2745 1115 t 1114 ));
DATA(insert ( 2742 _money_ops PGNSP PGUID 2745 791 t 790 ));
DATA(insert ( 2742 _reltime_ops PGNSP PGUID 2745 1024 t 703 ));
DATA(insert ( 2742 _tinterval_ops PGNSP PGUID 2745 1025 t 704 ));
DATA(insert ( 403 uuid_ops PGNSP PGUID 2968 2950 t 0 ));
DATA(insert ( 405 uuid_ops PGNSP PGUID 2969 2950 t 0 ));
DATA(insert ( 403 enum_ops PGNSP PGUID 3522 3500 t 0 ));
DATA(insert ( 405 enum_ops PGNSP PGUID 3523 3500 t 0 ));
DATA(insert ( 403 tsvector_ops PGNSP PGUID 3626 3614 t 0 ));
DATA(insert ( 783 tsvector_ops PGNSP PGUID 3655 3614 t 3642 ));
DATA(insert ( 2742 tsvector_ops PGNSP PGUID 3659 3614 t 25 ));
DATA(insert ( 403 tsquery_ops PGNSP PGUID 3683 3615 t 0 ));
DATA(insert ( 783 tsquery_ops PGNSP PGUID 3702 3615 t 20 ));
#endif /* PG_OPCLASS_H */

1680
deps/libpq/include/catalog/pg_operator.h vendored Normal file

File diff suppressed because it is too large Load diff

143
deps/libpq/include/catalog/pg_opfamily.h vendored Normal file
View file

@ -0,0 +1,143 @@
/*-------------------------------------------------------------------------
*
* pg_opfamily.h
* definition of the system "opfamily" relation (pg_opfamily)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_opfamily.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_OPFAMILY_H
#define PG_OPFAMILY_H
#include "catalog/genbki.h"
/* ----------------
* pg_opfamily definition. cpp turns this into
* typedef struct FormData_pg_opfamily
* ----------------
*/
#define OperatorFamilyRelationId 2753
CATALOG(pg_opfamily,2753)
{
Oid opfmethod; /* index access method opfamily is for */
NameData opfname; /* name of this opfamily */
Oid opfnamespace; /* namespace of this opfamily */
Oid opfowner; /* opfamily owner */
} FormData_pg_opfamily;
/* ----------------
* Form_pg_opfamily corresponds to a pointer to a tuple with
* the format of pg_opfamily relation.
* ----------------
*/
typedef FormData_pg_opfamily *Form_pg_opfamily;
/* ----------------
* compiler constants for pg_opfamily
* ----------------
*/
#define Natts_pg_opfamily 4
#define Anum_pg_opfamily_opfmethod 1
#define Anum_pg_opfamily_opfname 2
#define Anum_pg_opfamily_opfnamespace 3
#define Anum_pg_opfamily_opfowner 4
/* ----------------
* initial contents of pg_opfamily
* ----------------
*/
DATA(insert OID = 421 ( 403 abstime_ops PGNSP PGUID ));
DATA(insert OID = 397 ( 403 array_ops PGNSP PGUID ));
DATA(insert OID = 627 ( 405 array_ops PGNSP PGUID ));
DATA(insert OID = 423 ( 403 bit_ops PGNSP PGUID ));
DATA(insert OID = 424 ( 403 bool_ops PGNSP PGUID ));
#define BOOL_BTREE_FAM_OID 424
DATA(insert OID = 426 ( 403 bpchar_ops PGNSP PGUID ));
#define BPCHAR_BTREE_FAM_OID 426
DATA(insert OID = 427 ( 405 bpchar_ops PGNSP PGUID ));
DATA(insert OID = 428 ( 403 bytea_ops PGNSP PGUID ));
#define BYTEA_BTREE_FAM_OID 428
DATA(insert OID = 429 ( 403 char_ops PGNSP PGUID ));
DATA(insert OID = 431 ( 405 char_ops PGNSP PGUID ));
DATA(insert OID = 434 ( 403 datetime_ops PGNSP PGUID ));
DATA(insert OID = 435 ( 405 date_ops PGNSP PGUID ));
DATA(insert OID = 1970 ( 403 float_ops PGNSP PGUID ));
DATA(insert OID = 1971 ( 405 float_ops PGNSP PGUID ));
DATA(insert OID = 1974 ( 403 network_ops PGNSP PGUID ));
#define NETWORK_BTREE_FAM_OID 1974
DATA(insert OID = 1975 ( 405 network_ops PGNSP PGUID ));
DATA(insert OID = 1976 ( 403 integer_ops PGNSP PGUID ));
#define INTEGER_BTREE_FAM_OID 1976
DATA(insert OID = 1977 ( 405 integer_ops PGNSP PGUID ));
DATA(insert OID = 1982 ( 403 interval_ops PGNSP PGUID ));
DATA(insert OID = 1983 ( 405 interval_ops PGNSP PGUID ));
DATA(insert OID = 1984 ( 403 macaddr_ops PGNSP PGUID ));
DATA(insert OID = 1985 ( 405 macaddr_ops PGNSP PGUID ));
DATA(insert OID = 1986 ( 403 name_ops PGNSP PGUID ));
#define NAME_BTREE_FAM_OID 1986
DATA(insert OID = 1987 ( 405 name_ops PGNSP PGUID ));
DATA(insert OID = 1988 ( 403 numeric_ops PGNSP PGUID ));
DATA(insert OID = 1998 ( 405 numeric_ops PGNSP PGUID ));
DATA(insert OID = 1989 ( 403 oid_ops PGNSP PGUID ));
#define OID_BTREE_FAM_OID 1989
DATA(insert OID = 1990 ( 405 oid_ops PGNSP PGUID ));
DATA(insert OID = 1991 ( 403 oidvector_ops PGNSP PGUID ));
DATA(insert OID = 1992 ( 405 oidvector_ops PGNSP PGUID ));
DATA(insert OID = 2994 ( 403 record_ops PGNSP PGUID ));
DATA(insert OID = 1994 ( 403 text_ops PGNSP PGUID ));
#define TEXT_BTREE_FAM_OID 1994
DATA(insert OID = 1995 ( 405 text_ops PGNSP PGUID ));
DATA(insert OID = 1996 ( 403 time_ops PGNSP PGUID ));
DATA(insert OID = 1997 ( 405 time_ops PGNSP PGUID ));
DATA(insert OID = 1999 ( 405 timestamptz_ops PGNSP PGUID ));
DATA(insert OID = 2000 ( 403 timetz_ops PGNSP PGUID ));
DATA(insert OID = 2001 ( 405 timetz_ops PGNSP PGUID ));
DATA(insert OID = 2002 ( 403 varbit_ops PGNSP PGUID ));
DATA(insert OID = 2040 ( 405 timestamp_ops PGNSP PGUID ));
DATA(insert OID = 2095 ( 403 text_pattern_ops PGNSP PGUID ));
#define TEXT_PATTERN_BTREE_FAM_OID 2095
DATA(insert OID = 2097 ( 403 bpchar_pattern_ops PGNSP PGUID ));
#define BPCHAR_PATTERN_BTREE_FAM_OID 2097
DATA(insert OID = 2099 ( 403 money_ops PGNSP PGUID ));
DATA(insert OID = 2222 ( 405 bool_ops PGNSP PGUID ));
#define BOOL_HASH_FAM_OID 2222
DATA(insert OID = 2223 ( 405 bytea_ops PGNSP PGUID ));
DATA(insert OID = 2224 ( 405 int2vector_ops PGNSP PGUID ));
DATA(insert OID = 2789 ( 403 tid_ops PGNSP PGUID ));
DATA(insert OID = 2225 ( 405 xid_ops PGNSP PGUID ));
DATA(insert OID = 2226 ( 405 cid_ops PGNSP PGUID ));
DATA(insert OID = 2227 ( 405 abstime_ops PGNSP PGUID ));
DATA(insert OID = 2228 ( 405 reltime_ops PGNSP PGUID ));
DATA(insert OID = 2229 ( 405 text_pattern_ops PGNSP PGUID ));
DATA(insert OID = 2231 ( 405 bpchar_pattern_ops PGNSP PGUID ));
DATA(insert OID = 2233 ( 403 reltime_ops PGNSP PGUID ));
DATA(insert OID = 2234 ( 403 tinterval_ops PGNSP PGUID ));
DATA(insert OID = 2235 ( 405 aclitem_ops PGNSP PGUID ));
DATA(insert OID = 2593 ( 783 box_ops PGNSP PGUID ));
DATA(insert OID = 2594 ( 783 poly_ops PGNSP PGUID ));
DATA(insert OID = 2595 ( 783 circle_ops PGNSP PGUID ));
DATA(insert OID = 1029 ( 783 point_ops PGNSP PGUID ));
DATA(insert OID = 2745 ( 2742 array_ops PGNSP PGUID ));
DATA(insert OID = 2968 ( 403 uuid_ops PGNSP PGUID ));
DATA(insert OID = 2969 ( 405 uuid_ops PGNSP PGUID ));
DATA(insert OID = 3522 ( 403 enum_ops PGNSP PGUID ));
DATA(insert OID = 3523 ( 405 enum_ops PGNSP PGUID ));
DATA(insert OID = 3626 ( 403 tsvector_ops PGNSP PGUID ));
DATA(insert OID = 3655 ( 783 tsvector_ops PGNSP PGUID ));
DATA(insert OID = 3659 ( 2742 tsvector_ops PGNSP PGUID ));
DATA(insert OID = 3683 ( 403 tsquery_ops PGNSP PGUID ));
DATA(insert OID = 3702 ( 783 tsquery_ops PGNSP PGUID ));
#endif /* PG_OPFAMILY_H */

View file

@ -0,0 +1,79 @@
/*-------------------------------------------------------------------------
*
* pg_pltemplate.h
* definition of the system "PL template" relation (pg_pltemplate)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_pltemplate.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_PLTEMPLATE_H
#define PG_PLTEMPLATE_H
#include "catalog/genbki.h"
/* ----------------
* pg_pltemplate definition. cpp turns this into
* typedef struct FormData_pg_pltemplate
* ----------------
*/
#define PLTemplateRelationId 1136
CATALOG(pg_pltemplate,1136) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
{
NameData tmplname; /* name of PL */
bool tmpltrusted; /* PL is trusted? */
bool tmpldbacreate; /* PL is installable by db owner? */
text tmplhandler; /* name of call handler function */
text tmplinline; /* name of anonymous-block handler, or NULL */
text tmplvalidator; /* name of validator function, or NULL */
text tmpllibrary; /* path of shared library */
aclitem tmplacl[1]; /* access privileges for template */
} FormData_pg_pltemplate;
/* ----------------
* Form_pg_pltemplate corresponds to a pointer to a row with
* the format of pg_pltemplate relation.
* ----------------
*/
typedef FormData_pg_pltemplate *Form_pg_pltemplate;
/* ----------------
* compiler constants for pg_pltemplate
* ----------------
*/
#define Natts_pg_pltemplate 8
#define Anum_pg_pltemplate_tmplname 1
#define Anum_pg_pltemplate_tmpltrusted 2
#define Anum_pg_pltemplate_tmpldbacreate 3
#define Anum_pg_pltemplate_tmplhandler 4
#define Anum_pg_pltemplate_tmplinline 5
#define Anum_pg_pltemplate_tmplvalidator 6
#define Anum_pg_pltemplate_tmpllibrary 7
#define Anum_pg_pltemplate_tmplacl 8
/* ----------------
* initial contents of pg_pltemplate
* ----------------
*/
DATA(insert ( "plpgsql" t t "plpgsql_call_handler" "plpgsql_inline_handler" "plpgsql_validator" "$libdir/plpgsql" _null_ ));
DATA(insert ( "pltcl" t t "pltcl_call_handler" _null_ _null_ "$libdir/pltcl" _null_ ));
DATA(insert ( "pltclu" f f "pltclu_call_handler" _null_ _null_ "$libdir/pltcl" _null_ ));
DATA(insert ( "plperl" t t "plperl_call_handler" "plperl_inline_handler" "plperl_validator" "$libdir/plperl" _null_ ));
DATA(insert ( "plperlu" f f "plperlu_call_handler" "plperlu_inline_handler" "plperlu_validator" "$libdir/plperl" _null_ ));
DATA(insert ( "plpythonu" f f "plpython_call_handler" "plpython_inline_handler" "plpython_validator" "$libdir/plpython2" _null_ ));
DATA(insert ( "plpython2u" f f "plpython2_call_handler" "plpython2_inline_handler" "plpython2_validator" "$libdir/plpython2" _null_ ));
DATA(insert ( "plpython3u" f f "plpython3_call_handler" "plpython3_inline_handler" "plpython3_validator" "$libdir/plpython3" _null_ ));
#endif /* PG_PLTEMPLATE_H */

4352
deps/libpq/include/catalog/pg_proc.h vendored Normal file

File diff suppressed because it is too large Load diff

44
deps/libpq/include/catalog/pg_proc_fn.h vendored Normal file
View file

@ -0,0 +1,44 @@
/*-------------------------------------------------------------------------
*
* pg_proc_fn.h
* prototypes for functions in catalog/pg_proc.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_proc_fn.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_PROC_FN_H
#define PG_PROC_FN_H
#include "nodes/pg_list.h"
extern Oid ProcedureCreate(const char *procedureName,
Oid procNamespace,
bool replace,
bool returnsSet,
Oid returnType,
Oid languageObjectId,
Oid languageValidator,
const char *prosrc,
const char *probin,
bool isAgg,
bool isWindowFunc,
bool security_definer,
bool isStrict,
char volatility,
oidvector *parameterTypes,
Datum allParameterTypes,
Datum parameterModes,
Datum parameterNames,
List *parameterDefaults,
Datum proconfig,
float4 procost,
float4 prorows);
extern bool function_parse_error_transpose(const char *prosrc);
#endif /* PG_PROC_FN_H */

69
deps/libpq/include/catalog/pg_rewrite.h vendored Normal file
View file

@ -0,0 +1,69 @@
/*-------------------------------------------------------------------------
*
* pg_rewrite.h
* definition of the system "rewrite-rule" relation (pg_rewrite)
* along with the relation's initial contents.
*
* As of Postgres 7.3, the primary key for this table is <ev_class, rulename>
* --- ie, rule names are only unique among the rules of a given table.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_rewrite.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_REWRITE_H
#define PG_REWRITE_H
#include "catalog/genbki.h"
/* ----------------
* pg_rewrite definition. cpp turns this into
* typedef struct FormData_pg_rewrite
* ----------------
*/
#define RewriteRelationId 2618
CATALOG(pg_rewrite,2618)
{
NameData rulename;
Oid ev_class;
int2 ev_attr;
char ev_type;
char ev_enabled;
bool is_instead;
/* NB: remaining fields must be accessed via heap_getattr */
pg_node_tree ev_qual;
pg_node_tree ev_action;
} FormData_pg_rewrite;
/* ----------------
* Form_pg_rewrite corresponds to a pointer to a tuple with
* the format of pg_rewrite relation.
* ----------------
*/
typedef FormData_pg_rewrite *Form_pg_rewrite;
/* ----------------
* compiler constants for pg_rewrite
* ----------------
*/
#define Natts_pg_rewrite 8
#define Anum_pg_rewrite_rulename 1
#define Anum_pg_rewrite_ev_class 2
#define Anum_pg_rewrite_ev_attr 3
#define Anum_pg_rewrite_ev_type 4
#define Anum_pg_rewrite_ev_enabled 5
#define Anum_pg_rewrite_is_instead 6
#define Anum_pg_rewrite_ev_qual 7
#define Anum_pg_rewrite_ev_action 8
#endif /* PG_REWRITE_H */

View file

@ -0,0 +1,43 @@
/* -------------------------------------------------------------------------
*
* pg_seclabel.h
* definition of the system "security label" relation (pg_seclabel)
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* -------------------------------------------------------------------------
*/
#ifndef PG_SECLABEL_H
#define PG_SECLABEL_H
#include "catalog/genbki.h"
/* ----------------
* pg_seclabel definition. cpp turns this into
* typedef struct FormData_pg_seclabel
* ----------------
*/
#define SecLabelRelationId 3596
CATALOG(pg_seclabel,3596) BKI_WITHOUT_OIDS
{
Oid objoid; /* OID of the object itself */
Oid classoid; /* OID of table containing the object */
int4 objsubid; /* column number, or 0 if not used */
text provider; /* name of label provider */
text label; /* security label of the object */
} FormData_pg_seclabel;
/* ----------------
* compiler constants for pg_seclabel
* ----------------
*/
#define Natts_pg_seclabel 5
#define Anum_pg_seclabel_objoid 1
#define Anum_pg_seclabel_classoid 2
#define Anum_pg_seclabel_objsubid 3
#define Anum_pg_seclabel_provider 4
#define Anum_pg_seclabel_label 5
#endif /* PG_SECLABEL_H */

View file

@ -0,0 +1,90 @@
/*-------------------------------------------------------------------------
*
* pg_shdepend.h
* definition of the system "shared dependency" relation (pg_shdepend)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_shdepend.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_SHDEPEND_H
#define PG_SHDEPEND_H
#include "catalog/genbki.h"
/* ----------------
* pg_shdepend definition. cpp turns this into
* typedef struct FormData_pg_shdepend
* ----------------
*/
#define SharedDependRelationId 1214
CATALOG(pg_shdepend,1214) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
{
/*
* Identification of the dependent (referencing) object.
*
* These fields are all zeroes for a DEPENDENCY_PIN entry. Also, dbid can
* be zero to denote a shared object.
*/
Oid dbid; /* OID of database containing object */
Oid classid; /* OID of table containing object */
Oid objid; /* OID of object itself */
int4 objsubid; /* column number, or 0 if not used */
/*
* Identification of the independent (referenced) object. This is always
* a shared object, so we need no database ID field. We don't bother with
* a sub-object ID either.
*/
Oid refclassid; /* OID of table containing object */
Oid refobjid; /* OID of object itself */
/*
* Precise semantics of the relationship are specified by the deptype
* field. See SharedDependencyType in catalog/dependency.h.
*/
char deptype; /* see codes in dependency.h */
} FormData_pg_shdepend;
/* ----------------
* Form_pg_shdepend corresponds to a pointer to a row with
* the format of pg_shdepend relation.
* ----------------
*/
typedef FormData_pg_shdepend *Form_pg_shdepend;
/* ----------------
* compiler constants for pg_shdepend
* ----------------
*/
#define Natts_pg_shdepend 7
#define Anum_pg_shdepend_dbid 1
#define Anum_pg_shdepend_classid 2
#define Anum_pg_shdepend_objid 3
#define Anum_pg_shdepend_objsubid 4
#define Anum_pg_shdepend_refclassid 5
#define Anum_pg_shdepend_refobjid 6
#define Anum_pg_shdepend_deptype 7
/*
* pg_shdepend has no preloaded contents; system-defined dependencies are
* loaded into it during a late stage of the initdb process.
*
* NOTE: we do not represent all possible dependency pairs in pg_shdepend;
* for example, there's not much value in creating an explicit dependency
* from a relation to its database. Currently, only dependencies on roles
* are explicitly stored in pg_shdepend.
*/
#endif /* PG_SHDEPEND_H */

View file

@ -0,0 +1,75 @@
/*-------------------------------------------------------------------------
*
* pg_shdescription.h
* definition of the system "shared description" relation
* (pg_shdescription)
*
* NOTE: an object is identified by the OID of the row that primarily
* defines the object, plus the OID of the table that that row appears in.
* For example, a database is identified by the OID of its pg_database row
* plus the pg_class OID of table pg_database. This allows unique
* identification of objects without assuming that OIDs are unique
* across tables.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_shdescription.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_SHDESCRIPTION_H
#define PG_SHDESCRIPTION_H
#include "catalog/genbki.h"
/* ----------------
* pg_shdescription definition. cpp turns this into
* typedef struct FormData_pg_shdescription
* ----------------
*/
#define SharedDescriptionRelationId 2396
CATALOG(pg_shdescription,2396) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
{
Oid objoid; /* OID of object itself */
Oid classoid; /* OID of table containing object */
text description; /* description of object */
} FormData_pg_shdescription;
/* ----------------
* Form_pg_shdescription corresponds to a pointer to a tuple with
* the format of pg_shdescription relation.
* ----------------
*/
typedef FormData_pg_shdescription *Form_pg_shdescription;
/* ----------------
* compiler constants for pg_shdescription
* ----------------
*/
#define Natts_pg_shdescription 3
#define Anum_pg_shdescription_objoid 1
#define Anum_pg_shdescription_classoid 2
#define Anum_pg_shdescription_description 3
/* ----------------
* initial contents of pg_shdescription
* ----------------
*/
/*
* Because the contents of this table are taken from the other *.h files,
* there is no initialization here. The initial contents are extracted
* by genbki.pl and loaded during initdb.
*/
#endif /* PG_SHDESCRIPTION_H */

View file

@ -0,0 +1,263 @@
/*-------------------------------------------------------------------------
*
* pg_statistic.h
* definition of the system "statistic" relation (pg_statistic)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_statistic.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_STATISTIC_H
#define PG_STATISTIC_H
#include "catalog/genbki.h"
/*
* The CATALOG definition has to refer to the type of stavaluesN as
* "anyarray" so that bootstrap mode recognizes it. There is no real
* typedef for that, however. Since the fields are potentially-null and
* therefore can't be accessed directly from C code, there is no particular
* need for the C struct definition to show a valid field type --- instead
* we just make it int.
*/
#define anyarray int
/* ----------------
* pg_statistic definition. cpp turns this into
* typedef struct FormData_pg_statistic
* ----------------
*/
#define StatisticRelationId 2619
CATALOG(pg_statistic,2619) BKI_WITHOUT_OIDS
{
/* These fields form the unique key for the entry: */
Oid starelid; /* relation containing attribute */
int2 staattnum; /* attribute (column) stats are for */
bool stainherit; /* true if inheritance children are included */
/* the fraction of the column's entries that are NULL: */
float4 stanullfrac;
/*
* stawidth is the average width in bytes of non-null entries. For
* fixed-width datatypes this is of course the same as the typlen, but for
* var-width types it is more useful. Note that this is the average width
* of the data as actually stored, post-TOASTing (eg, for a
* moved-out-of-line value, only the size of the pointer object is
* counted). This is the appropriate definition for the primary use of
* the statistic, which is to estimate sizes of in-memory hash tables of
* tuples.
*/
int4 stawidth;
/* ----------------
* stadistinct indicates the (approximate) number of distinct non-null
* data values in the column. The interpretation is:
* 0 unknown or not computed
* > 0 actual number of distinct values
* < 0 negative of multiplier for number of rows
* The special negative case allows us to cope with columns that are
* unique (stadistinct = -1) or nearly so (for example, a column in
* which values appear about twice on the average could be represented
* by stadistinct = -0.5). Because the number-of-rows statistic in
* pg_class may be updated more frequently than pg_statistic is, it's
* important to be able to describe such situations as a multiple of
* the number of rows, rather than a fixed number of distinct values.
* But in other cases a fixed number is correct (eg, a boolean column).
* ----------------
*/
float4 stadistinct;
/* ----------------
* To allow keeping statistics on different kinds of datatypes,
* we do not hard-wire any particular meaning for the remaining
* statistical fields. Instead, we provide several "slots" in which
* statistical data can be placed. Each slot includes:
* kind integer code identifying kind of data
* op OID of associated operator, if needed
* numbers float4 array (for statistical values)
* values anyarray (for representations of data values)
* The ID and operator fields are never NULL; they are zeroes in an
* unused slot. The numbers and values fields are NULL in an unused
* slot, and might also be NULL in a used slot if the slot kind has
* no need for one or the other.
* ----------------
*/
int2 stakind1;
int2 stakind2;
int2 stakind3;
int2 stakind4;
Oid staop1;
Oid staop2;
Oid staop3;
Oid staop4;
/*
* THE REST OF THESE ARE VARIABLE LENGTH FIELDS, and may even be absent
* (NULL). They cannot be accessed as C struct entries; you have to use
* the full field access machinery (heap_getattr) for them. We declare
* them here for the catalog machinery.
*/
float4 stanumbers1[1];
float4 stanumbers2[1];
float4 stanumbers3[1];
float4 stanumbers4[1];
/*
* Values in these arrays are values of the column's data type. We
* presently have to cheat quite a bit to allow polymorphic arrays of this
* kind, but perhaps someday it'll be a less bogus facility.
*/
anyarray stavalues1;
anyarray stavalues2;
anyarray stavalues3;
anyarray stavalues4;
} FormData_pg_statistic;
#define STATISTIC_NUM_SLOTS 4
#undef anyarray
/* ----------------
* Form_pg_statistic corresponds to a pointer to a tuple with
* the format of pg_statistic relation.
* ----------------
*/
typedef FormData_pg_statistic *Form_pg_statistic;
/* ----------------
* compiler constants for pg_statistic
* ----------------
*/
#define Natts_pg_statistic 22
#define Anum_pg_statistic_starelid 1
#define Anum_pg_statistic_staattnum 2
#define Anum_pg_statistic_stainherit 3
#define Anum_pg_statistic_stanullfrac 4
#define Anum_pg_statistic_stawidth 5
#define Anum_pg_statistic_stadistinct 6
#define Anum_pg_statistic_stakind1 7
#define Anum_pg_statistic_stakind2 8
#define Anum_pg_statistic_stakind3 9
#define Anum_pg_statistic_stakind4 10
#define Anum_pg_statistic_staop1 11
#define Anum_pg_statistic_staop2 12
#define Anum_pg_statistic_staop3 13
#define Anum_pg_statistic_staop4 14
#define Anum_pg_statistic_stanumbers1 15
#define Anum_pg_statistic_stanumbers2 16
#define Anum_pg_statistic_stanumbers3 17
#define Anum_pg_statistic_stanumbers4 18
#define Anum_pg_statistic_stavalues1 19
#define Anum_pg_statistic_stavalues2 20
#define Anum_pg_statistic_stavalues3 21
#define Anum_pg_statistic_stavalues4 22
/*
* Currently, three statistical slot "kinds" are defined: most common values,
* histogram, and correlation. Additional "kinds" will probably appear in
* future to help cope with non-scalar datatypes. Also, custom data types
* can define their own "kind" codes by mutual agreement between a custom
* typanalyze routine and the selectivity estimation functions of the type's
* operators.
*
* Code reading the pg_statistic relation should not assume that a particular
* data "kind" will appear in any particular slot. Instead, search the
* stakind fields to see if the desired data is available. (The standard
* function get_attstatsslot() may be used for this.)
*/
/*
* The present allocation of "kind" codes is:
*
* 1-99: reserved for assignment by the core PostgreSQL project
* (values in this range will be documented in this file)
* 100-199: reserved for assignment by the PostGIS project
* (values to be documented in PostGIS documentation)
* 200-299: reserved for assignment by the ESRI ST_Geometry project
* (values to be documented in ESRI ST_Geometry documentation)
* 300-9999: reserved for future public assignments
*
* For private use you may choose a "kind" code at random in the range
* 10000-30000. However, for code that is to be widely disseminated it is
* better to obtain a publicly defined "kind" code by request from the
* PostgreSQL Global Development Group.
*/
/*
* In a "most common values" slot, staop is the OID of the "=" operator
* used to decide whether values are the same or not. stavalues contains
* the K most common non-null values appearing in the column, and stanumbers
* contains their frequencies (fractions of total row count). The values
* shall be ordered in decreasing frequency. Note that since the arrays are
* variable-size, K may be chosen by the statistics collector. Values should
* not appear in MCV unless they have been observed to occur more than once;
* a unique column will have no MCV slot.
*/
#define STATISTIC_KIND_MCV 1
/*
* A "histogram" slot describes the distribution of scalar data. staop is
* the OID of the "<" operator that describes the sort ordering. (In theory,
* more than one histogram could appear, if a datatype has more than one
* useful sort operator.) stavalues contains M (>=2) non-null values that
* divide the non-null column data values into M-1 bins of approximately equal
* population. The first stavalues item is the MIN and the last is the MAX.
* stanumbers is not used and should be NULL. IMPORTANT POINT: if an MCV
* slot is also provided, then the histogram describes the data distribution
* *after removing the values listed in MCV* (thus, it's a "compressed
* histogram" in the technical parlance). This allows a more accurate
* representation of the distribution of a column with some very-common
* values. In a column with only a few distinct values, it's possible that
* the MCV list describes the entire data population; in this case the
* histogram reduces to empty and should be omitted.
*/
#define STATISTIC_KIND_HISTOGRAM 2
/*
* A "correlation" slot describes the correlation between the physical order
* of table tuples and the ordering of data values of this column, as seen
* by the "<" operator identified by staop. (As with the histogram, more
* than one entry could theoretically appear.) stavalues is not used and
* should be NULL. stanumbers contains a single entry, the correlation
* coefficient between the sequence of data values and the sequence of
* their actual tuple positions. The coefficient ranges from +1 to -1.
*/
#define STATISTIC_KIND_CORRELATION 3
/*
* A "most common elements" slot is similar to a "most common values" slot,
* except that it stores the most common non-null *elements* of the column
* values. This is useful when the column datatype is an array or some other
* type with identifiable elements (for instance, tsvector). staop contains
* the equality operator appropriate to the element type. stavalues contains
* the most common element values, and stanumbers their frequencies. Unlike
* MCV slots, frequencies are measured as the fraction of non-null rows the
* element value appears in, not the frequency of all rows. Also unlike
* MCV slots, the values are sorted into order (to support binary search
* for a particular value). Since this puts the minimum and maximum
* frequencies at unpredictable spots in stanumbers, there are two extra
* members of stanumbers, holding copies of the minimum and maximum
* frequencies.
*
* Note: in current usage for tsvector columns, the stavalues elements are of
* type text, even though their representation within tsvector is not
* exactly text.
*/
#define STATISTIC_KIND_MCELEM 4
#endif /* PG_STATISTIC_H */

View file

@ -0,0 +1,65 @@
/*-------------------------------------------------------------------------
*
* pg_tablespace.h
* definition of the system "tablespace" relation (pg_tablespace)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_tablespace.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TABLESPACE_H
#define PG_TABLESPACE_H
#include "catalog/genbki.h"
/* ----------------
* pg_tablespace definition. cpp turns this into
* typedef struct FormData_pg_tablespace
* ----------------
*/
#define TableSpaceRelationId 1213
CATALOG(pg_tablespace,1213) BKI_SHARED_RELATION
{
NameData spcname; /* tablespace name */
Oid spcowner; /* owner of tablespace */
text spclocation; /* physical location (VAR LENGTH) */
aclitem spcacl[1]; /* access permissions (VAR LENGTH) */
text spcoptions[1]; /* per-tablespace options */
} FormData_pg_tablespace;
/* ----------------
* Form_pg_tablespace corresponds to a pointer to a tuple with
* the format of pg_tablespace relation.
* ----------------
*/
typedef FormData_pg_tablespace *Form_pg_tablespace;
/* ----------------
* compiler constants for pg_tablespace
* ----------------
*/
#define Natts_pg_tablespace 5
#define Anum_pg_tablespace_spcname 1
#define Anum_pg_tablespace_spcowner 2
#define Anum_pg_tablespace_spclocation 3
#define Anum_pg_tablespace_spcacl 4
#define Anum_pg_tablespace_spcoptions 5
DATA(insert OID = 1663 ( pg_default PGUID "" _null_ _null_ ));
DATA(insert OID = 1664 ( pg_global PGUID "" _null_ _null_ ));
#define DEFAULTTABLESPACE_OID 1663
#define GLOBALTABLESPACE_OID 1664
#endif /* PG_TABLESPACE_H */

139
deps/libpq/include/catalog/pg_trigger.h vendored Normal file
View file

@ -0,0 +1,139 @@
/*-------------------------------------------------------------------------
*
* pg_trigger.h
* definition of the system "trigger" relation (pg_trigger)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_trigger.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TRIGGER_H
#define PG_TRIGGER_H
#include "catalog/genbki.h"
/* ----------------
* pg_trigger definition. cpp turns this into
* typedef struct FormData_pg_trigger
*
* Note: when tgconstraint is nonzero, tgconstrrelid, tgconstrindid,
* tgdeferrable, and tginitdeferred are largely redundant with the referenced
* pg_constraint entry. However, it is possible for a non-deferrable trigger
* to be associated with a deferrable constraint.
* ----------------
*/
#define TriggerRelationId 2620
CATALOG(pg_trigger,2620)
{
Oid tgrelid; /* relation trigger is attached to */
NameData tgname; /* trigger's name */
Oid tgfoid; /* OID of function to be called */
int2 tgtype; /* BEFORE/AFTER/INSTEAD, UPDATE/DELETE/INSERT,
* ROW/STATEMENT; see below */
char tgenabled; /* trigger's firing configuration WRT
* session_replication_role */
bool tgisinternal; /* trigger is system-generated */
Oid tgconstrrelid; /* constraint's FROM table, if any */
Oid tgconstrindid; /* constraint's supporting index, if any */
Oid tgconstraint; /* associated pg_constraint entry, if any */
bool tgdeferrable; /* constraint trigger is deferrable */
bool tginitdeferred; /* constraint trigger is deferred initially */
int2 tgnargs; /* # of extra arguments in tgargs */
/* VARIABLE LENGTH FIELDS (note: tgattr and tgargs must not be null) */
int2vector tgattr; /* column numbers, if trigger is on columns */
bytea tgargs; /* first\000second\000tgnargs\000 */
pg_node_tree tgqual; /* WHEN expression, or NULL if none */
} FormData_pg_trigger;
/* ----------------
* Form_pg_trigger corresponds to a pointer to a tuple with
* the format of pg_trigger relation.
* ----------------
*/
typedef FormData_pg_trigger *Form_pg_trigger;
/* ----------------
* compiler constants for pg_trigger
* ----------------
*/
#define Natts_pg_trigger 15
#define Anum_pg_trigger_tgrelid 1
#define Anum_pg_trigger_tgname 2
#define Anum_pg_trigger_tgfoid 3
#define Anum_pg_trigger_tgtype 4
#define Anum_pg_trigger_tgenabled 5
#define Anum_pg_trigger_tgisinternal 6
#define Anum_pg_trigger_tgconstrrelid 7
#define Anum_pg_trigger_tgconstrindid 8
#define Anum_pg_trigger_tgconstraint 9
#define Anum_pg_trigger_tgdeferrable 10
#define Anum_pg_trigger_tginitdeferred 11
#define Anum_pg_trigger_tgnargs 12
#define Anum_pg_trigger_tgattr 13
#define Anum_pg_trigger_tgargs 14
#define Anum_pg_trigger_tgqual 15
/* Bits within tgtype */
#define TRIGGER_TYPE_ROW (1 << 0)
#define TRIGGER_TYPE_BEFORE (1 << 1)
#define TRIGGER_TYPE_INSERT (1 << 2)
#define TRIGGER_TYPE_DELETE (1 << 3)
#define TRIGGER_TYPE_UPDATE (1 << 4)
#define TRIGGER_TYPE_TRUNCATE (1 << 5)
#define TRIGGER_TYPE_INSTEAD (1 << 6)
#define TRIGGER_TYPE_LEVEL_MASK (TRIGGER_TYPE_ROW)
#define TRIGGER_TYPE_STATEMENT 0
/* Note bits within TRIGGER_TYPE_TIMING_MASK aren't adjacent */
#define TRIGGER_TYPE_TIMING_MASK \
(TRIGGER_TYPE_BEFORE | TRIGGER_TYPE_INSTEAD)
#define TRIGGER_TYPE_AFTER 0
#define TRIGGER_TYPE_EVENT_MASK \
(TRIGGER_TYPE_INSERT | TRIGGER_TYPE_DELETE | TRIGGER_TYPE_UPDATE | TRIGGER_TYPE_TRUNCATE)
/* Macros for manipulating tgtype */
#define TRIGGER_CLEAR_TYPE(type) ((type) = 0)
#define TRIGGER_SETT_ROW(type) ((type) |= TRIGGER_TYPE_ROW)
#define TRIGGER_SETT_STATEMENT(type) ((type) |= TRIGGER_TYPE_STATEMENT)
#define TRIGGER_SETT_BEFORE(type) ((type) |= TRIGGER_TYPE_BEFORE)
#define TRIGGER_SETT_AFTER(type) ((type) |= TRIGGER_TYPE_AFTER)
#define TRIGGER_SETT_INSTEAD(type) ((type) |= TRIGGER_TYPE_INSTEAD)
#define TRIGGER_SETT_INSERT(type) ((type) |= TRIGGER_TYPE_INSERT)
#define TRIGGER_SETT_DELETE(type) ((type) |= TRIGGER_TYPE_DELETE)
#define TRIGGER_SETT_UPDATE(type) ((type) |= TRIGGER_TYPE_UPDATE)
#define TRIGGER_SETT_TRUNCATE(type) ((type) |= TRIGGER_TYPE_TRUNCATE)
#define TRIGGER_FOR_ROW(type) ((type) & TRIGGER_TYPE_ROW)
#define TRIGGER_FOR_BEFORE(type) (((type) & TRIGGER_TYPE_TIMING_MASK) == TRIGGER_TYPE_BEFORE)
#define TRIGGER_FOR_AFTER(type) (((type) & TRIGGER_TYPE_TIMING_MASK) == TRIGGER_TYPE_AFTER)
#define TRIGGER_FOR_INSTEAD(type) (((type) & TRIGGER_TYPE_TIMING_MASK) == TRIGGER_TYPE_INSTEAD)
#define TRIGGER_FOR_INSERT(type) ((type) & TRIGGER_TYPE_INSERT)
#define TRIGGER_FOR_DELETE(type) ((type) & TRIGGER_TYPE_DELETE)
#define TRIGGER_FOR_UPDATE(type) ((type) & TRIGGER_TYPE_UPDATE)
#define TRIGGER_FOR_TRUNCATE(type) ((type) & TRIGGER_TYPE_TRUNCATE)
/*
* Efficient macro for checking if tgtype matches a particular level
* (TRIGGER_TYPE_ROW or TRIGGER_TYPE_STATEMENT), timing (TRIGGER_TYPE_BEFORE,
* TRIGGER_TYPE_AFTER or TRIGGER_TYPE_INSTEAD), and event (TRIGGER_TYPE_INSERT,
* TRIGGER_TYPE_DELETE, TRIGGER_TYPE_UPDATE, or TRIGGER_TYPE_TRUNCATE). Note
* that a tgtype can match more than one event, but only one level or timing.
*/
#define TRIGGER_TYPE_MATCHES(type, level, timing, event) \
(((type) & (TRIGGER_TYPE_LEVEL_MASK | TRIGGER_TYPE_TIMING_MASK | (event))) == ((level) | (timing) | (event)))
#endif /* PG_TRIGGER_H */

View file

@ -0,0 +1,60 @@
/*-------------------------------------------------------------------------
*
* pg_ts_config.h
* definition of configuration of tsearch
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_config.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TS_CONFIG_H
#define PG_TS_CONFIG_H
#include "catalog/genbki.h"
/* ----------------
* pg_ts_config definition. cpp turns this into
* typedef struct FormData_pg_ts_config
* ----------------
*/
#define TSConfigRelationId 3602
CATALOG(pg_ts_config,3602)
{
NameData cfgname; /* name of configuration */
Oid cfgnamespace; /* name space */
Oid cfgowner; /* owner */
Oid cfgparser; /* OID of parser (in pg_ts_parser) */
} FormData_pg_ts_config;
typedef FormData_pg_ts_config *Form_pg_ts_config;
/* ----------------
* compiler constants for pg_ts_config
* ----------------
*/
#define Natts_pg_ts_config 4
#define Anum_pg_ts_config_cfgname 1
#define Anum_pg_ts_config_cfgnamespace 2
#define Anum_pg_ts_config_cfgowner 3
#define Anum_pg_ts_config_cfgparser 4
/* ----------------
* initial contents of pg_ts_config
* ----------------
*/
DATA(insert OID = 3748 ( "simple" PGNSP PGUID 3722 ));
DESCR("simple configuration");
#endif /* PG_TS_CONFIG_H */

View file

@ -0,0 +1,78 @@
/*-------------------------------------------------------------------------
*
* pg_ts_config_map.h
* definition of token mappings for configurations of tsearch
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_config_map.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TS_CONFIG_MAP_H
#define PG_TS_CONFIG_MAP_H
#include "catalog/genbki.h"
/* ----------------
* pg_ts_config_map definition. cpp turns this into
* typedef struct FormData_pg_ts_config_map
* ----------------
*/
#define TSConfigMapRelationId 3603
CATALOG(pg_ts_config_map,3603) BKI_WITHOUT_OIDS
{
Oid mapcfg; /* OID of configuration owning this entry */
int4 maptokentype; /* token type from parser */
int4 mapseqno; /* order in which to consult dictionaries */
Oid mapdict; /* dictionary to consult */
} FormData_pg_ts_config_map;
typedef FormData_pg_ts_config_map *Form_pg_ts_config_map;
/* ----------------
* compiler constants for pg_ts_config_map
* ----------------
*/
#define Natts_pg_ts_config_map 4
#define Anum_pg_ts_config_map_mapcfg 1
#define Anum_pg_ts_config_map_maptokentype 2
#define Anum_pg_ts_config_map_mapseqno 3
#define Anum_pg_ts_config_map_mapdict 4
/* ----------------
* initial contents of pg_ts_config_map
* ----------------
*/
DATA(insert ( 3748 1 1 3765 ));
DATA(insert ( 3748 2 1 3765 ));
DATA(insert ( 3748 3 1 3765 ));
DATA(insert ( 3748 4 1 3765 ));
DATA(insert ( 3748 5 1 3765 ));
DATA(insert ( 3748 6 1 3765 ));
DATA(insert ( 3748 7 1 3765 ));
DATA(insert ( 3748 8 1 3765 ));
DATA(insert ( 3748 9 1 3765 ));
DATA(insert ( 3748 10 1 3765 ));
DATA(insert ( 3748 11 1 3765 ));
DATA(insert ( 3748 15 1 3765 ));
DATA(insert ( 3748 16 1 3765 ));
DATA(insert ( 3748 17 1 3765 ));
DATA(insert ( 3748 18 1 3765 ));
DATA(insert ( 3748 19 1 3765 ));
DATA(insert ( 3748 20 1 3765 ));
DATA(insert ( 3748 21 1 3765 ));
DATA(insert ( 3748 22 1 3765 ));
#endif /* PG_TS_CONFIG_MAP_H */

63
deps/libpq/include/catalog/pg_ts_dict.h vendored Normal file
View file

@ -0,0 +1,63 @@
/*-------------------------------------------------------------------------
*
* pg_ts_dict.h
* definition of dictionaries for tsearch
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_dict.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TS_DICT_H
#define PG_TS_DICT_H
#include "catalog/genbki.h"
/* ----------------
* pg_ts_dict definition. cpp turns this into
* typedef struct FormData_pg_ts_dict
* ----------------
*/
#define TSDictionaryRelationId 3600
CATALOG(pg_ts_dict,3600)
{
NameData dictname; /* dictionary name */
Oid dictnamespace; /* name space */
Oid dictowner; /* owner */
Oid dicttemplate; /* dictionary's template */
text dictinitoption; /* options passed to dict_init() */
} FormData_pg_ts_dict;
typedef FormData_pg_ts_dict *Form_pg_ts_dict;
/* ----------------
* compiler constants for pg_ts_dict
* ----------------
*/
#define Natts_pg_ts_dict 5
#define Anum_pg_ts_dict_dictname 1
#define Anum_pg_ts_dict_dictnamespace 2
#define Anum_pg_ts_dict_dictowner 3
#define Anum_pg_ts_dict_dicttemplate 4
#define Anum_pg_ts_dict_dictinitoption 5
/* ----------------
* initial contents of pg_ts_dict
* ----------------
*/
DATA(insert OID = 3765 ( "simple" PGNSP PGUID 3727 _null_));
DESCR("simple dictionary: just lower case and check for stopword");
#endif /* PG_TS_DICT_H */

View file

@ -0,0 +1,67 @@
/*-------------------------------------------------------------------------
*
* pg_ts_parser.h
* definition of parsers for tsearch
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_parser.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TS_PARSER_H
#define PG_TS_PARSER_H
#include "catalog/genbki.h"
/* ----------------
* pg_ts_parser definition. cpp turns this into
* typedef struct FormData_pg_ts_parser
* ----------------
*/
#define TSParserRelationId 3601
CATALOG(pg_ts_parser,3601)
{
NameData prsname; /* parser's name */
Oid prsnamespace; /* name space */
regproc prsstart; /* init parsing session */
regproc prstoken; /* return next token */
regproc prsend; /* finalize parsing session */
regproc prsheadline; /* return data for headline creation */
regproc prslextype; /* return descriptions of lexeme's types */
} FormData_pg_ts_parser;
typedef FormData_pg_ts_parser *Form_pg_ts_parser;
/* ----------------
* compiler constants for pg_ts_parser
* ----------------
*/
#define Natts_pg_ts_parser 7
#define Anum_pg_ts_parser_prsname 1
#define Anum_pg_ts_parser_prsnamespace 2
#define Anum_pg_ts_parser_prsstart 3
#define Anum_pg_ts_parser_prstoken 4
#define Anum_pg_ts_parser_prsend 5
#define Anum_pg_ts_parser_prsheadline 6
#define Anum_pg_ts_parser_prslextype 7
/* ----------------
* initial contents of pg_ts_parser
* ----------------
*/
DATA(insert OID = 3722 ( "default" PGNSP prsd_start prsd_nexttoken prsd_end prsd_headline prsd_lextype ));
DESCR("default word parser");
#endif /* PG_TS_PARSER_H */

View file

@ -0,0 +1,67 @@
/*-------------------------------------------------------------------------
*
* pg_ts_template.h
* definition of dictionary templates for tsearch
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_template.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
* XXX do NOT break up DATA() statements into multiple lines!
* the scripts are not as smart as you might think...
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TS_TEMPLATE_H
#define PG_TS_TEMPLATE_H
#include "catalog/genbki.h"
/* ----------------
* pg_ts_template definition. cpp turns this into
* typedef struct FormData_pg_ts_template
* ----------------
*/
#define TSTemplateRelationId 3764
CATALOG(pg_ts_template,3764)
{
NameData tmplname; /* template name */
Oid tmplnamespace; /* name space */
regproc tmplinit; /* initialization method of dict (may be 0) */
regproc tmpllexize; /* base method of dictionary */
} FormData_pg_ts_template;
typedef FormData_pg_ts_template *Form_pg_ts_template;
/* ----------------
* compiler constants for pg_ts_template
* ----------------
*/
#define Natts_pg_ts_template 4
#define Anum_pg_ts_template_tmplname 1
#define Anum_pg_ts_template_tmplnamespace 2
#define Anum_pg_ts_template_tmplinit 3
#define Anum_pg_ts_template_tmpllexize 4
/* ----------------
* initial contents of pg_ts_template
* ----------------
*/
DATA(insert OID = 3727 ( "simple" PGNSP dsimple_init dsimple_lexize ));
DESCR("simple dictionary: just lower case and check for stopword");
DATA(insert OID = 3730 ( "synonym" PGNSP dsynonym_init dsynonym_lexize ));
DESCR("synonym dictionary: replace word by its synonym");
DATA(insert OID = 3733 ( "ispell" PGNSP dispell_init dispell_lexize ));
DESCR("ispell dictionary");
DATA(insert OID = 3742 ( "thesaurus" PGNSP thesaurus_init thesaurus_lexize ));
DESCR("thesaurus dictionary: phrase by phrase substitution");
#endif /* PG_TS_TEMPLATE_H */

669
deps/libpq/include/catalog/pg_type.h vendored Normal file
View file

@ -0,0 +1,669 @@
/*-------------------------------------------------------------------------
*
* pg_type.h
* definition of the system "type" relation (pg_type)
* along with the relation's initial contents.
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_type.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TYPE_H
#define PG_TYPE_H
#include "catalog/genbki.h"
/* ----------------
* pg_type definition. cpp turns this into
* typedef struct FormData_pg_type
*
* Some of the values in a pg_type instance are copied into
* pg_attribute instances. Some parts of Postgres use the pg_type copy,
* while others use the pg_attribute copy, so they must match.
* See struct FormData_pg_attribute for details.
* ----------------
*/
#define TypeRelationId 1247
#define TypeRelation_Rowtype_Id 71
CATALOG(pg_type,1247) BKI_BOOTSTRAP BKI_ROWTYPE_OID(71) BKI_SCHEMA_MACRO
{
NameData typname; /* type name */
Oid typnamespace; /* OID of namespace containing this type */
Oid typowner; /* type owner */
/*
* For a fixed-size type, typlen is the number of bytes we use to
* represent a value of this type, e.g. 4 for an int4. But for a
* variable-length type, typlen is negative. We use -1 to indicate a
* "varlena" type (one that has a length word), -2 to indicate a
* null-terminated C string.
*/
int2 typlen;
/*
* typbyval determines whether internal Postgres routines pass a value of
* this type by value or by reference. typbyval had better be FALSE if
* the length is not 1, 2, or 4 (or 8 on 8-byte-Datum machines).
* Variable-length types are always passed by reference. Note that
* typbyval can be false even if the length would allow pass-by-value;
* this is currently true for type float4, for example.
*/
bool typbyval;
/*
* typtype is 'b' for a base type, 'c' for a composite type (e.g., a
* table's rowtype), 'd' for a domain type, 'e' for an enum type, or 'p'
* for a pseudo-type. (Use the TYPTYPE macros below.)
*
* If typtype is 'c', typrelid is the OID of the class' entry in pg_class.
*/
char typtype;
/*
* typcategory and typispreferred help the parser distinguish preferred
* and non-preferred coercions. The category can be any single ASCII
* character (but not \0). The categories used for built-in types are
* identified by the TYPCATEGORY macros below.
*/
char typcategory; /* arbitrary type classification */
bool typispreferred; /* is type "preferred" within its category? */
/*
* If typisdefined is false, the entry is only a placeholder (forward
* reference). We know the type name, but not yet anything else about it.
*/
bool typisdefined;
char typdelim; /* delimiter for arrays of this type */
Oid typrelid; /* 0 if not a composite type */
/*
* If typelem is not 0 then it identifies another row in pg_type. The
* current type can then be subscripted like an array yielding values of
* type typelem. A non-zero typelem does not guarantee this type to be a
* "real" array type; some ordinary fixed-length types can also be
* subscripted (e.g., name, point). Variable-length types can *not* be
* turned into pseudo-arrays like that. Hence, the way to determine
* whether a type is a "true" array type is if:
*
* typelem != 0 and typlen == -1.
*/
Oid typelem;
/*
* If there is a "true" array type having this type as element type,
* typarray links to it. Zero if no associated "true" array type.
*/
Oid typarray;
/*
* I/O conversion procedures for the datatype.
*/
regproc typinput; /* text format (required) */
regproc typoutput;
regproc typreceive; /* binary format (optional) */
regproc typsend;
/*
* I/O functions for optional type modifiers.
*/
regproc typmodin;
regproc typmodout;
/*
* Custom ANALYZE procedure for the datatype (0 selects the default).
*/
regproc typanalyze;
/* ----------------
* typalign is the alignment required when storing a value of this
* type. It applies to storage on disk as well as most
* representations of the value inside Postgres. When multiple values
* are stored consecutively, such as in the representation of a
* complete row on disk, padding is inserted before a datum of this
* type so that it begins on the specified boundary. The alignment
* reference is the beginning of the first datum in the sequence.
*
* 'c' = CHAR alignment, ie no alignment needed.
* 's' = SHORT alignment (2 bytes on most machines).
* 'i' = INT alignment (4 bytes on most machines).
* 'd' = DOUBLE alignment (8 bytes on many machines, but by no means all).
*
* See include/access/tupmacs.h for the macros that compute these
* alignment requirements. Note also that we allow the nominal alignment
* to be violated when storing "packed" varlenas; the TOAST mechanism
* takes care of hiding that from most code.
*
* NOTE: for types used in system tables, it is critical that the
* size and alignment defined in pg_type agree with the way that the
* compiler will lay out the field in a struct representing a table row.
* ----------------
*/
char typalign;
/* ----------------
* typstorage tells if the type is prepared for toasting and what
* the default strategy for attributes of this type should be.
*
* 'p' PLAIN type not prepared for toasting
* 'e' EXTERNAL external storage possible, don't try to compress
* 'x' EXTENDED try to compress and store external if required
* 'm' MAIN like 'x' but try to keep in main tuple
* ----------------
*/
char typstorage;
/*
* This flag represents a "NOT NULL" constraint against this datatype.
*
* If true, the attnotnull column for a corresponding table column using
* this datatype will always enforce the NOT NULL constraint.
*
* Used primarily for domain types.
*/
bool typnotnull;
/*
* Domains use typbasetype to show the base (or domain) type that the
* domain is based on. Zero if the type is not a domain.
*/
Oid typbasetype;
/*
* Domains use typtypmod to record the typmod to be applied to their base
* type (-1 if base type does not use a typmod). -1 if this type is not a
* domain.
*/
int4 typtypmod;
/*
* typndims is the declared number of dimensions for an array domain type
* (i.e., typbasetype is an array type). Otherwise zero.
*/
int4 typndims;
/*
* Collation: 0 if type cannot use collations, DEFAULT_COLLATION_OID for
* collatable base types, possibly other OID for domains
*/
Oid typcollation;
/*
* If typdefaultbin is not NULL, it is the nodeToString representation of
* a default expression for the type. Currently this is only used for
* domains.
*/
pg_node_tree typdefaultbin; /* VARIABLE LENGTH FIELD */
/*
* typdefault is NULL if the type has no associated default value. If
* typdefaultbin is not NULL, typdefault must contain a human-readable
* version of the default expression represented by typdefaultbin. If
* typdefaultbin is NULL and typdefault is not, then typdefault is the
* external representation of the type's default value, which may be fed
* to the type's input converter to produce a constant.
*/
text typdefault; /* VARIABLE LENGTH FIELD */
} FormData_pg_type;
/* ----------------
* Form_pg_type corresponds to a pointer to a row with
* the format of pg_type relation.
* ----------------
*/
typedef FormData_pg_type *Form_pg_type;
/* ----------------
* compiler constants for pg_type
* ----------------
*/
#define Natts_pg_type 29
#define Anum_pg_type_typname 1
#define Anum_pg_type_typnamespace 2
#define Anum_pg_type_typowner 3
#define Anum_pg_type_typlen 4
#define Anum_pg_type_typbyval 5
#define Anum_pg_type_typtype 6
#define Anum_pg_type_typcategory 7
#define Anum_pg_type_typispreferred 8
#define Anum_pg_type_typisdefined 9
#define Anum_pg_type_typdelim 10
#define Anum_pg_type_typrelid 11
#define Anum_pg_type_typelem 12
#define Anum_pg_type_typarray 13
#define Anum_pg_type_typinput 14
#define Anum_pg_type_typoutput 15
#define Anum_pg_type_typreceive 16
#define Anum_pg_type_typsend 17
#define Anum_pg_type_typmodin 18
#define Anum_pg_type_typmodout 19
#define Anum_pg_type_typanalyze 20
#define Anum_pg_type_typalign 21
#define Anum_pg_type_typstorage 22
#define Anum_pg_type_typnotnull 23
#define Anum_pg_type_typbasetype 24
#define Anum_pg_type_typtypmod 25
#define Anum_pg_type_typndims 26
#define Anum_pg_type_typcollation 27
#define Anum_pg_type_typdefaultbin 28
#define Anum_pg_type_typdefault 29
/* ----------------
* initial contents of pg_type
* ----------------
*/
/*
* Keep the following ordered by OID so that later changes can be made more
* easily.
*
* For types used in the system catalogs, make sure the values here match
* TypInfo[] in bootstrap.c.
*/
/* OIDS 1 - 99 */
DATA(insert OID = 16 ( bool PGNSP PGUID 1 t b B t t \054 0 0 1000 boolin boolout boolrecv boolsend - - - c p f 0 -1 0 0 _null_ _null_ ));
DESCR("boolean, 'true'/'false'");
#define BOOLOID 16
DATA(insert OID = 17 ( bytea PGNSP PGUID -1 f b U f t \054 0 0 1001 byteain byteaout bytearecv byteasend - - - i x f 0 -1 0 0 _null_ _null_ ));
DESCR("variable-length string, binary values escaped");
#define BYTEAOID 17
DATA(insert OID = 18 ( char PGNSP PGUID 1 t b S f t \054 0 0 1002 charin charout charrecv charsend - - - c p f 0 -1 0 0 _null_ _null_ ));
DESCR("single character");
#define CHAROID 18
DATA(insert OID = 19 ( name PGNSP PGUID NAMEDATALEN f b S f t \054 0 18 1003 namein nameout namerecv namesend - - - c p f 0 -1 0 0 _null_ _null_ ));
DESCR("63-character type for storing system identifiers");
#define NAMEOID 19
DATA(insert OID = 20 ( int8 PGNSP PGUID 8 FLOAT8PASSBYVAL b N f t \054 0 0 1016 int8in int8out int8recv int8send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("~18 digit integer, 8-byte storage");
#define INT8OID 20
DATA(insert OID = 21 ( int2 PGNSP PGUID 2 t b N f t \054 0 0 1005 int2in int2out int2recv int2send - - - s p f 0 -1 0 0 _null_ _null_ ));
DESCR("-32 thousand to 32 thousand, 2-byte storage");
#define INT2OID 21
DATA(insert OID = 22 ( int2vector PGNSP PGUID -1 f b A f t \054 0 21 1006 int2vectorin int2vectorout int2vectorrecv int2vectorsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("array of int2, used in system tables");
#define INT2VECTOROID 22
DATA(insert OID = 23 ( int4 PGNSP PGUID 4 t b N f t \054 0 0 1007 int4in int4out int4recv int4send - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("-2 billion to 2 billion integer, 4-byte storage");
#define INT4OID 23
DATA(insert OID = 24 ( regproc PGNSP PGUID 4 t b N f t \054 0 0 1008 regprocin regprocout regprocrecv regprocsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered procedure");
#define REGPROCOID 24
DATA(insert OID = 25 ( text PGNSP PGUID -1 f b S t t \054 0 0 1009 textin textout textrecv textsend - - - i x f 0 -1 0 100 _null_ _null_ ));
DESCR("variable-length string, no limit specified");
#define TEXTOID 25
DATA(insert OID = 26 ( oid PGNSP PGUID 4 t b N t t \054 0 0 1028 oidin oidout oidrecv oidsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("object identifier(oid), maximum 4 billion");
#define OIDOID 26
DATA(insert OID = 27 ( tid PGNSP PGUID 6 f b U f t \054 0 0 1010 tidin tidout tidrecv tidsend - - - s p f 0 -1 0 0 _null_ _null_ ));
DESCR("(block, offset), physical location of tuple");
#define TIDOID 27
DATA(insert OID = 28 ( xid PGNSP PGUID 4 t b U f t \054 0 0 1011 xidin xidout xidrecv xidsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("transaction id");
#define XIDOID 28
DATA(insert OID = 29 ( cid PGNSP PGUID 4 t b U f t \054 0 0 1012 cidin cidout cidrecv cidsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("command identifier type, sequence in transaction id");
#define CIDOID 29
DATA(insert OID = 30 ( oidvector PGNSP PGUID -1 f b A f t \054 0 26 1013 oidvectorin oidvectorout oidvectorrecv oidvectorsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("array of oids, used in system tables");
#define OIDVECTOROID 30
/* hand-built rowtype entries for bootstrapped catalogs */
/* NB: OIDs assigned here must match the BKI_ROWTYPE_OID declarations */
DATA(insert OID = 71 ( pg_type PGNSP PGUID -1 f c C f t \054 1247 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 75 ( pg_attribute PGNSP PGUID -1 f c C f t \054 1249 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 81 ( pg_proc PGNSP PGUID -1 f c C f t \054 1255 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 83 ( pg_class PGNSP PGUID -1 f c C f t \054 1259 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ ));
/* OIDS 100 - 199 */
DATA(insert OID = 142 ( xml PGNSP PGUID -1 f b U f t \054 0 0 143 xml_in xml_out xml_recv xml_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DESCR("XML content");
#define XMLOID 142
DATA(insert OID = 143 ( _xml PGNSP PGUID -1 f b A f t \054 0 142 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 194 ( pg_node_tree PGNSP PGUID -1 f b S f t \054 0 0 0 pg_node_tree_in pg_node_tree_out pg_node_tree_recv pg_node_tree_send - - - i x f 0 -1 0 100 _null_ _null_ ));
DESCR("string representing an internal node tree");
#define PGNODETREEOID 194
/* OIDS 200 - 299 */
DATA(insert OID = 210 ( smgr PGNSP PGUID 2 t b U f t \054 0 0 0 smgrin smgrout - - - - - s p f 0 -1 0 0 _null_ _null_ ));
DESCR("storage manager");
/* OIDS 300 - 399 */
/* OIDS 400 - 499 */
/* OIDS 500 - 599 */
/* OIDS 600 - 699 */
DATA(insert OID = 600 ( point PGNSP PGUID 16 f b G f t \054 0 701 1017 point_in point_out point_recv point_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric point '(x, y)'");
#define POINTOID 600
DATA(insert OID = 601 ( lseg PGNSP PGUID 32 f b G f t \054 0 600 1018 lseg_in lseg_out lseg_recv lseg_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric line segment '(pt1,pt2)'");
#define LSEGOID 601
DATA(insert OID = 602 ( path PGNSP PGUID -1 f b G f t \054 0 0 1019 path_in path_out path_recv path_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric path '(pt1,...)'");
#define PATHOID 602
DATA(insert OID = 603 ( box PGNSP PGUID 32 f b G f t \073 0 600 1020 box_in box_out box_recv box_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric box '(lower left,upper right)'");
#define BOXOID 603
DATA(insert OID = 604 ( polygon PGNSP PGUID -1 f b G f t \054 0 0 1027 poly_in poly_out poly_recv poly_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric polygon '(pt1,...)'");
#define POLYGONOID 604
DATA(insert OID = 628 ( line PGNSP PGUID 32 f b G f t \054 0 701 629 line_in line_out line_recv line_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric line (not implemented)");
#define LINEOID 628
DATA(insert OID = 629 ( _line PGNSP PGUID -1 f b A f t \054 0 628 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DESCR("");
/* OIDS 700 - 799 */
DATA(insert OID = 700 ( float4 PGNSP PGUID 4 FLOAT4PASSBYVAL b N f t \054 0 0 1021 float4in float4out float4recv float4send - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("single-precision floating point number, 4-byte storage");
#define FLOAT4OID 700
DATA(insert OID = 701 ( float8 PGNSP PGUID 8 FLOAT8PASSBYVAL b N t t \054 0 0 1022 float8in float8out float8recv float8send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("double-precision floating point number, 8-byte storage");
#define FLOAT8OID 701
DATA(insert OID = 702 ( abstime PGNSP PGUID 4 t b D f t \054 0 0 1023 abstimein abstimeout abstimerecv abstimesend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("absolute, limited-range date and time (Unix system time)");
#define ABSTIMEOID 702
DATA(insert OID = 703 ( reltime PGNSP PGUID 4 t b T f t \054 0 0 1024 reltimein reltimeout reltimerecv reltimesend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("relative, limited-range time interval (Unix delta time)");
#define RELTIMEOID 703
DATA(insert OID = 704 ( tinterval PGNSP PGUID 12 f b T f t \054 0 0 1025 tintervalin tintervalout tintervalrecv tintervalsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("(abstime,abstime), time interval");
#define TINTERVALOID 704
DATA(insert OID = 705 ( unknown PGNSP PGUID -2 f b X f t \054 0 0 0 unknownin unknownout unknownrecv unknownsend - - - c p f 0 -1 0 0 _null_ _null_ ));
DESCR("");
#define UNKNOWNOID 705
DATA(insert OID = 718 ( circle PGNSP PGUID 24 f b G f t \054 0 0 719 circle_in circle_out circle_recv circle_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("geometric circle '(center,radius)'");
#define CIRCLEOID 718
DATA(insert OID = 719 ( _circle PGNSP PGUID -1 f b A f t \054 0 718 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 790 ( money PGNSP PGUID 8 FLOAT8PASSBYVAL b N f t \054 0 0 791 cash_in cash_out cash_recv cash_send - - - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("monetary amounts, $d,ddd.cc");
#define CASHOID 790
DATA(insert OID = 791 ( _money PGNSP PGUID -1 f b A f t \054 0 790 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
/* OIDS 800 - 899 */
DATA(insert OID = 829 ( macaddr PGNSP PGUID 6 f b U f t \054 0 0 1040 macaddr_in macaddr_out macaddr_recv macaddr_send - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("XX:XX:XX:XX:XX:XX, MAC address");
#define MACADDROID 829
DATA(insert OID = 869 ( inet PGNSP PGUID -1 f b I t t \054 0 0 1041 inet_in inet_out inet_recv inet_send - - - i m f 0 -1 0 0 _null_ _null_ ));
DESCR("IP address/netmask, host address, netmask optional");
#define INETOID 869
DATA(insert OID = 650 ( cidr PGNSP PGUID -1 f b I f t \054 0 0 651 cidr_in cidr_out cidr_recv cidr_send - - - i m f 0 -1 0 0 _null_ _null_ ));
DESCR("network IP address/netmask, network address");
#define CIDROID 650
/* OIDS 900 - 999 */
/* OIDS 1000 - 1099 */
DATA(insert OID = 1000 ( _bool PGNSP PGUID -1 f b A f t \054 0 16 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1001 ( _bytea PGNSP PGUID -1 f b A f t \054 0 17 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1002 ( _char PGNSP PGUID -1 f b A f t \054 0 18 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1003 ( _name PGNSP PGUID -1 f b A f t \054 0 19 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1005 ( _int2 PGNSP PGUID -1 f b A f t \054 0 21 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1006 ( _int2vector PGNSP PGUID -1 f b A f t \054 0 22 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1007 ( _int4 PGNSP PGUID -1 f b A f t \054 0 23 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
#define INT4ARRAYOID 1007
DATA(insert OID = 1008 ( _regproc PGNSP PGUID -1 f b A f t \054 0 24 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1009 ( _text PGNSP PGUID -1 f b A f t \054 0 25 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 100 _null_ _null_ ));
#define TEXTARRAYOID 1009
DATA(insert OID = 1028 ( _oid PGNSP PGUID -1 f b A f t \054 0 26 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1010 ( _tid PGNSP PGUID -1 f b A f t \054 0 27 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1011 ( _xid PGNSP PGUID -1 f b A f t \054 0 28 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1012 ( _cid PGNSP PGUID -1 f b A f t \054 0 29 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1013 ( _oidvector PGNSP PGUID -1 f b A f t \054 0 30 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1014 ( _bpchar PGNSP PGUID -1 f b A f t \054 0 1042 0 array_in array_out array_recv array_send bpchartypmodin bpchartypmodout - i x f 0 -1 0 100 _null_ _null_ ));
DATA(insert OID = 1015 ( _varchar PGNSP PGUID -1 f b A f t \054 0 1043 0 array_in array_out array_recv array_send varchartypmodin varchartypmodout - i x f 0 -1 0 100 _null_ _null_ ));
DATA(insert OID = 1016 ( _int8 PGNSP PGUID -1 f b A f t \054 0 20 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1017 ( _point PGNSP PGUID -1 f b A f t \054 0 600 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1018 ( _lseg PGNSP PGUID -1 f b A f t \054 0 601 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1019 ( _path PGNSP PGUID -1 f b A f t \054 0 602 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1020 ( _box PGNSP PGUID -1 f b A f t \073 0 603 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1021 ( _float4 PGNSP PGUID -1 f b A f t \054 0 700 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
#define FLOAT4ARRAYOID 1021
DATA(insert OID = 1022 ( _float8 PGNSP PGUID -1 f b A f t \054 0 701 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1023 ( _abstime PGNSP PGUID -1 f b A f t \054 0 702 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1024 ( _reltime PGNSP PGUID -1 f b A f t \054 0 703 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1025 ( _tinterval PGNSP PGUID -1 f b A f t \054 0 704 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1027 ( _polygon PGNSP PGUID -1 f b A f t \054 0 604 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1033 ( aclitem PGNSP PGUID 12 f b U f t \054 0 0 1034 aclitemin aclitemout - - - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("access control list");
#define ACLITEMOID 1033
DATA(insert OID = 1034 ( _aclitem PGNSP PGUID -1 f b A f t \054 0 1033 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1040 ( _macaddr PGNSP PGUID -1 f b A f t \054 0 829 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1041 ( _inet PGNSP PGUID -1 f b A f t \054 0 869 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 651 ( _cidr PGNSP PGUID -1 f b A f t \054 0 650 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1263 ( _cstring PGNSP PGUID -1 f b A f t \054 0 2275 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
#define CSTRINGARRAYOID 1263
DATA(insert OID = 1042 ( bpchar PGNSP PGUID -1 f b S f t \054 0 0 1014 bpcharin bpcharout bpcharrecv bpcharsend bpchartypmodin bpchartypmodout - i x f 0 -1 0 100 _null_ _null_ ));
DESCR("char(length), blank-padded string, fixed storage length");
#define BPCHAROID 1042
DATA(insert OID = 1043 ( varchar PGNSP PGUID -1 f b S f t \054 0 0 1015 varcharin varcharout varcharrecv varcharsend varchartypmodin varchartypmodout - i x f 0 -1 0 100 _null_ _null_ ));
DESCR("varchar(length), non-blank-padded string, variable storage length");
#define VARCHAROID 1043
DATA(insert OID = 1082 ( date PGNSP PGUID 4 t b D f t \054 0 0 1182 date_in date_out date_recv date_send - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("date");
#define DATEOID 1082
DATA(insert OID = 1083 ( time PGNSP PGUID 8 FLOAT8PASSBYVAL b D f t \054 0 0 1183 time_in time_out time_recv time_send timetypmodin timetypmodout - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("time of day");
#define TIMEOID 1083
/* OIDS 1100 - 1199 */
DATA(insert OID = 1114 ( timestamp PGNSP PGUID 8 FLOAT8PASSBYVAL b D f t \054 0 0 1115 timestamp_in timestamp_out timestamp_recv timestamp_send timestamptypmodin timestamptypmodout - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("date and time");
#define TIMESTAMPOID 1114
DATA(insert OID = 1115 ( _timestamp PGNSP PGUID -1 f b A f t \054 0 1114 0 array_in array_out array_recv array_send timestamptypmodin timestamptypmodout - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1182 ( _date PGNSP PGUID -1 f b A f t \054 0 1082 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1183 ( _time PGNSP PGUID -1 f b A f t \054 0 1083 0 array_in array_out array_recv array_send timetypmodin timetypmodout - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1184 ( timestamptz PGNSP PGUID 8 FLOAT8PASSBYVAL b D t t \054 0 0 1185 timestamptz_in timestamptz_out timestamptz_recv timestamptz_send timestamptztypmodin timestamptztypmodout - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("date and time with time zone");
#define TIMESTAMPTZOID 1184
DATA(insert OID = 1185 ( _timestamptz PGNSP PGUID -1 f b A f t \054 0 1184 0 array_in array_out array_recv array_send timestamptztypmodin timestamptztypmodout - d x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1186 ( interval PGNSP PGUID 16 f b T t t \054 0 0 1187 interval_in interval_out interval_recv interval_send intervaltypmodin intervaltypmodout - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("@ <number> <units>, time interval");
#define INTERVALOID 1186
DATA(insert OID = 1187 ( _interval PGNSP PGUID -1 f b A f t \054 0 1186 0 array_in array_out array_recv array_send intervaltypmodin intervaltypmodout - d x f 0 -1 0 0 _null_ _null_ ));
/* OIDS 1200 - 1299 */
DATA(insert OID = 1231 ( _numeric PGNSP PGUID -1 f b A f t \054 0 1700 0 array_in array_out array_recv array_send numerictypmodin numerictypmodout - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1266 ( timetz PGNSP PGUID 12 f b D f t \054 0 0 1270 timetz_in timetz_out timetz_recv timetz_send timetztypmodin timetztypmodout - d p f 0 -1 0 0 _null_ _null_ ));
DESCR("time of day with time zone");
#define TIMETZOID 1266
DATA(insert OID = 1270 ( _timetz PGNSP PGUID -1 f b A f t \054 0 1266 0 array_in array_out array_recv array_send timetztypmodin timetztypmodout - d x f 0 -1 0 0 _null_ _null_ ));
/* OIDS 1500 - 1599 */
DATA(insert OID = 1560 ( bit PGNSP PGUID -1 f b V f t \054 0 0 1561 bit_in bit_out bit_recv bit_send bittypmodin bittypmodout - i x f 0 -1 0 0 _null_ _null_ ));
DESCR("fixed-length bit string");
#define BITOID 1560
DATA(insert OID = 1561 ( _bit PGNSP PGUID -1 f b A f t \054 0 1560 0 array_in array_out array_recv array_send bittypmodin bittypmodout - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 1562 ( varbit PGNSP PGUID -1 f b V t t \054 0 0 1563 varbit_in varbit_out varbit_recv varbit_send varbittypmodin varbittypmodout - i x f 0 -1 0 0 _null_ _null_ ));
DESCR("variable-length bit string");
#define VARBITOID 1562
DATA(insert OID = 1563 ( _varbit PGNSP PGUID -1 f b A f t \054 0 1562 0 array_in array_out array_recv array_send varbittypmodin varbittypmodout - i x f 0 -1 0 0 _null_ _null_ ));
/* OIDS 1600 - 1699 */
/* OIDS 1700 - 1799 */
DATA(insert OID = 1700 ( numeric PGNSP PGUID -1 f b N f t \054 0 0 1231 numeric_in numeric_out numeric_recv numeric_send numerictypmodin numerictypmodout - i m f 0 -1 0 0 _null_ _null_ ));
DESCR("numeric(precision, decimal), arbitrary precision number");
#define NUMERICOID 1700
DATA(insert OID = 1790 ( refcursor PGNSP PGUID -1 f b U f t \054 0 0 2201 textin textout textrecv textsend - - - i x f 0 -1 0 0 _null_ _null_ ));
DESCR("reference to cursor (portal name)");
#define REFCURSOROID 1790
/* OIDS 2200 - 2299 */
DATA(insert OID = 2201 ( _refcursor PGNSP PGUID -1 f b A f t \054 0 1790 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2202 ( regprocedure PGNSP PGUID 4 t b N f t \054 0 0 2207 regprocedurein regprocedureout regprocedurerecv regproceduresend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered procedure (with args)");
#define REGPROCEDUREOID 2202
DATA(insert OID = 2203 ( regoper PGNSP PGUID 4 t b N f t \054 0 0 2208 regoperin regoperout regoperrecv regopersend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered operator");
#define REGOPEROID 2203
DATA(insert OID = 2204 ( regoperator PGNSP PGUID 4 t b N f t \054 0 0 2209 regoperatorin regoperatorout regoperatorrecv regoperatorsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered operator (with args)");
#define REGOPERATOROID 2204
DATA(insert OID = 2205 ( regclass PGNSP PGUID 4 t b N f t \054 0 0 2210 regclassin regclassout regclassrecv regclasssend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered class");
#define REGCLASSOID 2205
DATA(insert OID = 2206 ( regtype PGNSP PGUID 4 t b N f t \054 0 0 2211 regtypein regtypeout regtyperecv regtypesend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered type");
#define REGTYPEOID 2206
DATA(insert OID = 2207 ( _regprocedure PGNSP PGUID -1 f b A f t \054 0 2202 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2208 ( _regoper PGNSP PGUID -1 f b A f t \054 0 2203 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2209 ( _regoperator PGNSP PGUID -1 f b A f t \054 0 2204 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2210 ( _regclass PGNSP PGUID -1 f b A f t \054 0 2205 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2211 ( _regtype PGNSP PGUID -1 f b A f t \054 0 2206 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
#define REGTYPEARRAYOID 2211
/* uuid */
DATA(insert OID = 2950 ( uuid PGNSP PGUID 16 f b U f t \054 0 0 2951 uuid_in uuid_out uuid_recv uuid_send - - - c p f 0 -1 0 0 _null_ _null_ ));
DESCR("UUID datatype");
DATA(insert OID = 2951 ( _uuid PGNSP PGUID -1 f b A f t \054 0 2950 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
/* text search */
DATA(insert OID = 3614 ( tsvector PGNSP PGUID -1 f b U f t \054 0 0 3643 tsvectorin tsvectorout tsvectorrecv tsvectorsend - - ts_typanalyze i x f 0 -1 0 0 _null_ _null_ ));
DESCR("text representation for text search");
#define TSVECTOROID 3614
DATA(insert OID = 3642 ( gtsvector PGNSP PGUID -1 f b U f t \054 0 0 3644 gtsvectorin gtsvectorout - - - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("GiST index internal text representation for text search");
#define GTSVECTOROID 3642
DATA(insert OID = 3615 ( tsquery PGNSP PGUID -1 f b U f t \054 0 0 3645 tsqueryin tsqueryout tsqueryrecv tsquerysend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("query representation for text search");
#define TSQUERYOID 3615
DATA(insert OID = 3734 ( regconfig PGNSP PGUID 4 t b N f t \054 0 0 3735 regconfigin regconfigout regconfigrecv regconfigsend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered text search configuration");
#define REGCONFIGOID 3734
DATA(insert OID = 3769 ( regdictionary PGNSP PGUID 4 t b N f t \054 0 0 3770 regdictionaryin regdictionaryout regdictionaryrecv regdictionarysend - - - i p f 0 -1 0 0 _null_ _null_ ));
DESCR("registered text search dictionary");
#define REGDICTIONARYOID 3769
DATA(insert OID = 3643 ( _tsvector PGNSP PGUID -1 f b A f t \054 0 3614 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 3644 ( _gtsvector PGNSP PGUID -1 f b A f t \054 0 3642 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 3645 ( _tsquery PGNSP PGUID -1 f b A f t \054 0 3615 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 3735 ( _regconfig PGNSP PGUID -1 f b A f t \054 0 3734 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 3770 ( _regdictionary PGNSP PGUID -1 f b A f t \054 0 3769 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
DATA(insert OID = 2970 ( txid_snapshot PGNSP PGUID -1 f b U f t \054 0 0 2949 txid_snapshot_in txid_snapshot_out txid_snapshot_recv txid_snapshot_send - - - d x f 0 -1 0 0 _null_ _null_ ));
DESCR("txid snapshot");
DATA(insert OID = 2949 ( _txid_snapshot PGNSP PGUID -1 f b A f t \054 0 2970 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
/*
* pseudo-types
*
* types with typtype='p' represent various special cases in the type system.
*
* These cannot be used to define table columns, but are valid as function
* argument and result types (if supported by the function's implementation
* language).
*
* Note: cstring is a borderline case; it is still considered a pseudo-type,
* but there is now support for it in records and arrays. Perhaps we should
* just treat it as a regular base type?
*/
DATA(insert OID = 2249 ( record PGNSP PGUID -1 f p P f t \054 0 0 2287 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ ));
#define RECORDOID 2249
DATA(insert OID = 2287 ( _record PGNSP PGUID -1 f p P f t \054 0 2249 0 array_in array_out array_recv array_send - - - d x f 0 -1 0 0 _null_ _null_ ));
#define RECORDARRAYOID 2287
DATA(insert OID = 2275 ( cstring PGNSP PGUID -2 f p P f t \054 0 0 1263 cstring_in cstring_out cstring_recv cstring_send - - - c p f 0 -1 0 0 _null_ _null_ ));
#define CSTRINGOID 2275
DATA(insert OID = 2276 ( any PGNSP PGUID 4 t p P f t \054 0 0 0 any_in any_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define ANYOID 2276
DATA(insert OID = 2277 ( anyarray PGNSP PGUID -1 f p P f t \054 0 0 0 anyarray_in anyarray_out anyarray_recv anyarray_send - - - d x f 0 -1 0 0 _null_ _null_ ));
#define ANYARRAYOID 2277
DATA(insert OID = 2278 ( void PGNSP PGUID 4 t p P f t \054 0 0 0 void_in void_out void_recv void_send - - - i p f 0 -1 0 0 _null_ _null_ ));
#define VOIDOID 2278
DATA(insert OID = 2279 ( trigger PGNSP PGUID 4 t p P f t \054 0 0 0 trigger_in trigger_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define TRIGGEROID 2279
DATA(insert OID = 2280 ( language_handler PGNSP PGUID 4 t p P f t \054 0 0 0 language_handler_in language_handler_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define LANGUAGE_HANDLEROID 2280
DATA(insert OID = 2281 ( internal PGNSP PGUID SIZEOF_POINTER t p P f t \054 0 0 0 internal_in internal_out - - - - - ALIGNOF_POINTER p f 0 -1 0 0 _null_ _null_ ));
#define INTERNALOID 2281
DATA(insert OID = 2282 ( opaque PGNSP PGUID 4 t p P f t \054 0 0 0 opaque_in opaque_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define OPAQUEOID 2282
DATA(insert OID = 2283 ( anyelement PGNSP PGUID 4 t p P f t \054 0 0 0 anyelement_in anyelement_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define ANYELEMENTOID 2283
DATA(insert OID = 2776 ( anynonarray PGNSP PGUID 4 t p P f t \054 0 0 0 anynonarray_in anynonarray_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define ANYNONARRAYOID 2776
DATA(insert OID = 3500 ( anyenum PGNSP PGUID 4 t p P f t \054 0 0 0 anyenum_in anyenum_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define ANYENUMOID 3500
DATA(insert OID = 3115 ( fdw_handler PGNSP PGUID 4 t p P f t \054 0 0 0 fdw_handler_in fdw_handler_out - - - - - i p f 0 -1 0 0 _null_ _null_ ));
#define FDW_HANDLEROID 3115
/*
* macros
*/
#define TYPTYPE_BASE 'b' /* base type (ordinary scalar type) */
#define TYPTYPE_COMPOSITE 'c' /* composite (e.g., table's rowtype) */
#define TYPTYPE_DOMAIN 'd' /* domain over another type */
#define TYPTYPE_ENUM 'e' /* enumerated type */
#define TYPTYPE_PSEUDO 'p' /* pseudo-type */
#define TYPCATEGORY_INVALID '\0' /* not an allowed category */
#define TYPCATEGORY_ARRAY 'A'
#define TYPCATEGORY_BOOLEAN 'B'
#define TYPCATEGORY_COMPOSITE 'C'
#define TYPCATEGORY_DATETIME 'D'
#define TYPCATEGORY_ENUM 'E'
#define TYPCATEGORY_GEOMETRIC 'G'
#define TYPCATEGORY_NETWORK 'I' /* think INET */
#define TYPCATEGORY_NUMERIC 'N'
#define TYPCATEGORY_PSEUDOTYPE 'P'
#define TYPCATEGORY_STRING 'S'
#define TYPCATEGORY_TIMESPAN 'T'
#define TYPCATEGORY_USER 'U'
#define TYPCATEGORY_BITSTRING 'V' /* er ... "varbit"? */
#define TYPCATEGORY_UNKNOWN 'X'
/* Is a type OID a polymorphic pseudotype? (Beware of multiple evaluation) */
#define IsPolymorphicType(typid) \
((typid) == ANYELEMENTOID || \
(typid) == ANYARRAYOID || \
(typid) == ANYNONARRAYOID || \
(typid) == ANYENUMOID)
#endif /* PG_TYPE_H */

83
deps/libpq/include/catalog/pg_type_fn.h vendored Normal file
View file

@ -0,0 +1,83 @@
/*-------------------------------------------------------------------------
*
* pg_type_fn.h
* prototypes for functions in catalog/pg_type.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_type_fn.h
*
*-------------------------------------------------------------------------
*/
#ifndef PG_TYPE_FN_H
#define PG_TYPE_FN_H
#include "nodes/nodes.h"
extern Oid TypeShellMake(const char *typeName,
Oid typeNamespace,
Oid ownerId);
extern Oid TypeCreate(Oid newTypeOid,
const char *typeName,
Oid typeNamespace,
Oid relationOid,
char relationKind,
Oid ownerId,
int16 internalSize,
char typeType,
char typeCategory,
bool typePreferred,
char typDelim,
Oid inputProcedure,
Oid outputProcedure,
Oid receiveProcedure,
Oid sendProcedure,
Oid typmodinProcedure,
Oid typmodoutProcedure,
Oid analyzeProcedure,
Oid elementType,
bool isImplicitArray,
Oid arrayType,
Oid baseType,
const char *defaultTypeValue,
char *defaultTypeBin,
bool passedByValue,
char alignment,
char storage,
int32 typeMod,
int32 typNDims,
bool typeNotNull,
Oid typeCollation);
extern void GenerateTypeDependencies(Oid typeNamespace,
Oid typeObjectId,
Oid relationOid,
char relationKind,
Oid owner,
Oid inputProcedure,
Oid outputProcedure,
Oid receiveProcedure,
Oid sendProcedure,
Oid typmodinProcedure,
Oid typmodoutProcedure,
Oid analyzeProcedure,
Oid elementType,
bool isImplicitArray,
Oid baseType,
Oid typeCollation,
Node *defaultExpr,
bool rebuild);
extern void RenameTypeInternal(Oid typeOid, const char *newTypeName,
Oid typeNamespace);
extern char *makeArrayTypeName(const char *typeName, Oid typeNamespace);
extern bool moveArrayTypeName(Oid typeOid, const char *typeName,
Oid typeNamespace);
#endif /* PG_TYPE_FN_H */

View file

@ -0,0 +1,59 @@
/*-------------------------------------------------------------------------
*
* pg_user_mapping.h
* definition of the system "user mapping" relation (pg_user_mapping)
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_user_mapping.h
*
* NOTES
* the genbki.pl script reads this file and generates .bki
* information from the DATA() statements.
*
*-------------------------------------------------------------------------
*/
#ifndef PG_USER_MAPPING_H
#define PG_USER_MAPPING_H
#include "catalog/genbki.h"
/* ----------------
* pg_user_mapping definition. cpp turns this into
* typedef struct FormData_pg_user_mapping
* ----------------
*/
#define UserMappingRelationId 1418
CATALOG(pg_user_mapping,1418)
{
Oid umuser; /* Id of the user, InvalidOid if PUBLIC is
* wanted */
Oid umserver; /* server of this mapping */
/*
* VARIABLE LENGTH FIELDS start here. These fields may be NULL, too.
*/
text umoptions[1]; /* user mapping options */
} FormData_pg_user_mapping;
/* ----------------
* Form_pg_user_mapping corresponds to a pointer to a tuple with
* the format of pg_user_mapping relation.
* ----------------
*/
typedef FormData_pg_user_mapping *Form_pg_user_mapping;
/* ----------------
* compiler constants for pg_user_mapping
* ----------------
*/
#define Natts_pg_user_mapping 3
#define Anum_pg_user_mapping_umuser 1
#define Anum_pg_user_mapping_umserver 2
#define Anum_pg_user_mapping_umoptions 3
#endif /* PG_USER_MAPPING_H */

43
deps/libpq/include/catalog/storage.h vendored Normal file
View file

@ -0,0 +1,43 @@
/*-------------------------------------------------------------------------
*
* storage.h
* prototypes for functions in backend/catalog/storage.c
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/storage.h
*
*-------------------------------------------------------------------------
*/
#ifndef STORAGE_H
#define STORAGE_H
#include "access/xlog.h"
#include "lib/stringinfo.h"
#include "storage/block.h"
#include "storage/relfilenode.h"
#include "utils/relcache.h"
extern void RelationCreateStorage(RelFileNode rnode, char relpersistence);
extern void RelationDropStorage(Relation rel);
extern void RelationPreserveStorage(RelFileNode rnode);
extern void RelationTruncate(Relation rel, BlockNumber nblocks);
/*
* These functions used to be in storage/smgr/smgr.c, which explains the
* naming
*/
extern void smgrDoPendingDeletes(bool isCommit);
extern int smgrGetPendingDeletes(bool forCommit, RelFileNode **ptr);
extern void AtSubCommit_smgr(void);
extern void AtSubAbort_smgr(void);
extern void PostPrepare_smgr(void);
extern void log_smgrcreate(RelFileNode *rnode, ForkNumber forkNum);
extern void smgr_redo(XLogRecPtr lsn, XLogRecord *record);
extern void smgr_desc(StringInfo buf, uint8 xl_info, char *rec);
#endif /* STORAGE_H */

63
deps/libpq/include/catalog/toasting.h vendored Normal file
View file

@ -0,0 +1,63 @@
/*-------------------------------------------------------------------------
*
* toasting.h
* This file provides some definitions to support creation of toast tables
*
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/toasting.h
*
*-------------------------------------------------------------------------
*/
#ifndef TOASTING_H
#define TOASTING_H
/*
* toasting.c prototypes
*/
extern void AlterTableCreateToastTable(Oid relOid, Datum reloptions);
extern void BootstrapToastTable(char *relName,
Oid toastOid, Oid toastIndexOid);
/*
* This macro is just to keep the C compiler from spitting up on the
* upcoming commands for genbki.pl.
*/
#define DECLARE_TOAST(name,toastoid,indexoid) extern int no_such_variable
/*
* What follows are lines processed by genbki.pl to create the statements
* the bootstrap parser will turn into BootstrapToastTable commands.
* Each line specifies the system catalog that needs a toast table,
* the OID to assign to the toast table, and the OID to assign to the
* toast table's index. The reason we hard-wire these OIDs is that we
* need stable OIDs for shared relations, and that includes toast tables
* of shared relations.
*/
/* normal catalogs */
DECLARE_TOAST(pg_attrdef, 2830, 2831);
DECLARE_TOAST(pg_constraint, 2832, 2833);
DECLARE_TOAST(pg_description, 2834, 2835);
DECLARE_TOAST(pg_proc, 2836, 2837);
DECLARE_TOAST(pg_rewrite, 2838, 2839);
DECLARE_TOAST(pg_seclabel, 3598, 3599);
DECLARE_TOAST(pg_statistic, 2840, 2841);
DECLARE_TOAST(pg_trigger, 2336, 2337);
/* shared catalogs */
DECLARE_TOAST(pg_database, 2844, 2845);
#define PgDatabaseToastTable 2844
#define PgDatabaseToastIndex 2845
DECLARE_TOAST(pg_shdescription, 2846, 2847);
#define PgShdescriptionToastTable 2846
#define PgShdescriptionToastIndex 2847
DECLARE_TOAST(pg_db_role_setting, 2966, 2967);
#define PgDbRoleSettingToastTable 2966
#define PgDbRoleSettingToastIndex 2967
#endif /* TOASTING_H */

57
deps/libpq/include/catalog/unused_oids vendored Normal file
View file

@ -0,0 +1,57 @@
#!/bin/sh
#
# unused_oids
#
# src/include/catalog/unused_oids
#
# finds blocks of manually-assignable oids that have not already been
# claimed by post_hackers. primarily useful for finding available
# oids for new internal functions. the numbers printed are inclusive
# ranges of unused oids.
#
# before using a large empty block, make sure you aren't about
# to take over what was intended as expansion space for something
# else.
#
# run this script in src/include/catalog.
#
AWK="awk"
# Get FirstBootstrapObjectId from access/transam.h
FIRSTOBJECTID=`grep '#define[ ]*FirstBootstrapObjectId' ../access/transam.h | $AWK '{ print $3 }'`
export FIRSTOBJECTID
# this part (down to the uniq step) should match the duplicate_oids script
# note: we exclude BKI_BOOTSTRAP relations since they are expected to have
# matching DATA lines in pg_class.h and pg_type.h
cat pg_*.h toasting.h indexing.h | \
egrep -v -e '^CATALOG\(.*BKI_BOOTSTRAP' | \
sed -n -e 's/^DATA(insert *OID *= *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^CATALOG([^,]*, *\([0-9][0-9]*\).*BKI_ROWTYPE_OID(\([0-9][0-9]*\)).*$/\1,\2/p' \
-e 's/^CATALOG([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_INDEX([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_UNIQUE_INDEX([^,]*, *\([0-9][0-9]*\).*$/\1/p' \
-e 's/^DECLARE_TOAST([^,]*, *\([0-9][0-9]*\), *\([0-9][0-9]*\).*$/\1,\2/p' | \
tr ',' '\n' | \
sort -n | \
uniq | \
$AWK '
BEGIN {
last = 0;
}
/^[0-9]/ {
if ($1 > last + 1) {
if ($1 > last + 2) {
print last + 1, "-", $1 - 1;
} else {
print last + 1;
}
}
last = $1;
}
END {
print last + 1, "-", ENVIRON["FIRSTOBJECTID"]-1;
}'