1
/*-------------------------------------------------------------------------
4
* definition of the system "description" relation (pg_description)
6
* NOTE: an object is identified by the OID of the row that primarily
7
* defines the object, plus the OID of the table that that row appears in.
8
* For example, a function is identified by the OID of its pg_proc row
9
* plus the pg_class OID of table pg_proc. This allows unique identification
10
* of objects without assuming that OIDs are unique across tables.
12
* Since attributes don't have OIDs of their own, we identify an attribute
13
* comment by the objoid+classoid of its parent table, plus an "objsubid"
14
* giving the attribute column number. "objsubid" must be zero in a comment
15
* for a table itself, so that it is distinct from any column comment.
16
* Currently, objsubid is unused and zero for all other kinds of objects,
17
* but perhaps it might be useful someday to associate comments with
18
* constituent elements of other kinds of objects (arguments of a function,
22
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
23
* Portions Copyright (c) 1994, Regents of the University of California
28
* the genbki.sh script reads this file and generates .bki
29
* information from the DATA() statements.
31
* XXX do NOT break up DATA() statements into multiple lines!
32
* the scripts are not as smart as you might think...
34
*-------------------------------------------------------------------------
36
#ifndef PG_DESCRIPTION_H
37
#define PG_DESCRIPTION_H
39
#include "catalog/genbki.h"
42
* pg_description definition. cpp turns this into
43
* typedef struct FormData_pg_description
46
#define DescriptionRelationId 2609
48
CATALOG(pg_description,2609) BKI_WITHOUT_OIDS
50
Oid objoid; /* OID of object itself */
51
Oid classoid; /* OID of table containing object */
52
int4 objsubid; /* column number, or 0 if not used */
53
text description; /* description of object */
54
} FormData_pg_description;
57
* Form_pg_description corresponds to a pointer to a tuple with
58
* the format of pg_description relation.
61
typedef FormData_pg_description *Form_pg_description;
64
* compiler constants for pg_description
67
#define Natts_pg_description 4
68
#define Anum_pg_description_objoid 1
69
#define Anum_pg_description_classoid 2
70
#define Anum_pg_description_objsubid 3
71
#define Anum_pg_description_description 4
74
* initial contents of pg_description
79
* Because the contents of this table are taken from the other *.h files,
80
* there is no initialization here. The initial contents are extracted
81
* by genbki.sh and loaded during initdb.
84
#endif /* PG_DESCRIPTION_H */