PostgreSQL Source Code git master
Data Structures | Typedefs | Functions | Variables
bootstrap.c File Reference
#include "postgres.h"
#include <unistd.h>
#include <signal.h>
#include "access/genam.h"
#include "access/heapam.h"
#include "access/htup_details.h"
#include "access/tableam.h"
#include "access/toast_compression.h"
#include "access/xact.h"
#include "bootstrap/bootstrap.h"
#include "catalog/index.h"
#include "catalog/pg_collation.h"
#include "catalog/pg_type.h"
#include "common/link-canary.h"
#include "miscadmin.h"
#include "nodes/makefuncs.h"
#include "pg_getopt.h"
#include "postmaster/postmaster.h"
#include "storage/bufpage.h"
#include "storage/ipc.h"
#include "storage/proc.h"
#include "utils/builtins.h"
#include "utils/fmgroids.h"
#include "utils/guc.h"
#include "utils/memutils.h"
#include "utils/rel.h"
#include "utils/relmapper.h"
Include dependency graph for bootstrap.c:

Go to the source code of this file.

Data Structures

struct   typinfo
 
struct   typmap
 
struct   _IndexList
 

Typedefs

typedef struct _IndexList  IndexList
 

Functions

static void  CheckerModeMain (void)
 
static void  bootstrap_signals (void)
 
 
static void  populate_typ_list (void)
 
static Oid  gettype (char *type)
 
static void  cleanup (void)
 
void  BootstrapModeMain (int argc, char *argv[], bool check_only)
 
void  boot_openrel (char *relname)
 
void  closerel (char *relname)
 
void  DefineAttr (char *name, char *type, int attnum, int nullness)
 
void  InsertOneTuple (void)
 
void  InsertOneValue (char *value, int i)
 
void  InsertOneNull (int i)
 
void  boot_get_type_io_data (Oid typid, int16 *typlen, bool *typbyval, char *typalign, char *typdelim, Oid *typioparam, Oid *typinput, Oid *typoutput)
 
void  index_register (Oid heap, Oid ind, const IndexInfo *indexInfo)
 
void  build_indices (void)
 

Variables

 
 
int  numattr
 
static const struct typinfo  TypInfo []
 
static const int  n_types = sizeof(TypInfo) / sizeof(struct typinfo)
 
static ListTyp = NIL
 
static struct typmapAp = NULL
 
static Datum  values [MAXATTR]
 
static bool  Nulls [MAXATTR]
 
static MemoryContext  nogc = NULL
 
static IndexListILHead = NULL
 

Typedef Documentation

IndexList

typedef struct _IndexList IndexList

Function Documentation

AllocateAttribute()

static Form_pg_attribute AllocateAttribute ( void  )
static

Definition at line 916 of file bootstrap.c.

917{
918 return (Form_pg_attribute)
920}
void * MemoryContextAllocZero(MemoryContext context, Size size)
Definition: mcxt.c:1263
MemoryContext TopMemoryContext
Definition: mcxt.c:166
#define ATTRIBUTE_FIXED_PART_SIZE
Definition: pg_attribute.h:194
FormData_pg_attribute * Form_pg_attribute
Definition: pg_attribute.h:202

References ATTRIBUTE_FIXED_PART_SIZE, MemoryContextAllocZero(), and TopMemoryContext.

Referenced by boot_openrel(), and DefineAttr().

boot_get_type_io_data()

void boot_get_type_io_data ( Oid  typid,
int16typlen,
bool *  typbyval,
char *  typalign,
char *  typdelim,
Oidtypioparam,
Oidtypinput,
Oidtypoutput 
)

Definition at line 839 of file bootstrap.c.

847{
848 if (Typ != NIL)
849 {
850 /* We have the boot-time contents of pg_type, so use it */
851 struct typmap *ap = NULL;
852 ListCell *lc;
853
854 foreach(lc, Typ)
855 {
856 ap = lfirst(lc);
857 if (ap->am_oid == typid)
858 break;
859 }
860
861 if (!ap || ap->am_oid != typid)
862 elog(ERROR, "type OID %u not found in Typ list", typid);
863
864 *typlen = ap->am_typ.typlen;
865 *typbyval = ap->am_typ.typbyval;
866 *typalign = ap->am_typ.typalign;
867 *typdelim = ap->am_typ.typdelim;
868
869 /* XXX this logic must match getTypeIOParam() */
870 if (OidIsValid(ap->am_typ.typelem))
871 *typioparam = ap->am_typ.typelem;
872 else
873 *typioparam = typid;
874
875 *typinput = ap->am_typ.typinput;
876 *typoutput = ap->am_typ.typoutput;
877 }
878 else
879 {
880 /* We don't have pg_type yet, so use the hard-wired TypInfo array */
881 int typeindex;
882
883 for (typeindex = 0; typeindex < n_types; typeindex++)
884 {
885 if (TypInfo[typeindex].oid == typid)
886 break;
887 }
888 if (typeindex >= n_types)
889 elog(ERROR, "type OID %u not found in TypInfo", typid);
890
891 *typlen = TypInfo[typeindex].len;
892 *typbyval = TypInfo[typeindex].byval;
893 *typalign = TypInfo[typeindex].align;
894 /* We assume typdelim is ',' for all boot-time types */
895 *typdelim = ',';
896
897 /* XXX this logic must match getTypeIOParam() */
898 if (OidIsValid(TypInfo[typeindex].elem))
899 *typioparam = TypInfo[typeindex].elem;
900 else
901 *typioparam = typid;
902
903 *typinput = TypInfo[typeindex].inproc;
904 *typoutput = TypInfo[typeindex].outproc;
905 }
906}
static const int n_types
Definition: bootstrap.c:142
static const struct typinfo TypInfo[]
Definition: bootstrap.c:87
static List * Typ
Definition: bootstrap.c:150
#define OidIsValid(objectId)
Definition: c.h:774
#define ERROR
Definition: elog.h:39
#define elog(elevel,...)
Definition: elog.h:226
#define lfirst(lc)
Definition: pg_list.h:172
#define NIL
Definition: pg_list.h:68
char typalign
Definition: pg_type.h:176
char align
Definition: bootstrap.c:80
Oid outproc
Definition: bootstrap.c:84
int16 len
Definition: bootstrap.c:78
bool byval
Definition: bootstrap.c:79
Oid elem
Definition: bootstrap.c:77
Oid inproc
Definition: bootstrap.c:83
Definition: bootstrap.c:145
Oid am_oid
Definition: bootstrap.c:146
FormData_pg_type am_typ
Definition: bootstrap.c:147
Definition: pg_list.h:46

References typinfo::align, typmap::am_oid, typmap::am_typ, typinfo::byval, typinfo::elem, elog, ERROR, typinfo::inproc, typinfo::len, lfirst, n_types, NIL, OidIsValid, typinfo::outproc, Typ, typalign, and TypInfo.

Referenced by get_type_io_data(), and InsertOneValue().

boot_openrel()

void boot_openrel ( char *  relname )

Definition at line 442 of file bootstrap.c.

443{
444 int i;
445
446 if (strlen(relname) >= NAMEDATALEN)
447 relname[NAMEDATALEN - 1] = '0円';
448
449 /*
450 * pg_type must be filled before any OPEN command is executed, hence we
451 * can now populate Typ if we haven't yet.
452 */
453 if (Typ == NIL)
455
456 if (boot_reldesc != NULL)
457 closerel(NULL);
458
459 elog(DEBUG4, "open relation %s, attrsize %d",
461
464 for (i = 0; i < numattr; i++)
465 {
466 if (attrtypes[i] == NULL)
468 memmove(attrtypes[i],
471
472 {
474
475 elog(DEBUG4, "create attribute %d name %s len %d num %d type %u",
476 i, NameStr(at->attname), at->attlen, at->attnum,
477 at->atttypid);
478 }
479 }
480}
void closerel(char *relname)
Definition: bootstrap.c:487
static void populate_typ_list(void)
Definition: bootstrap.c:728
Relation boot_reldesc
Definition: bootstrap.c:58
Form_pg_attribute attrtypes[MAXATTR]
Definition: bootstrap.c:60
int numattr
Definition: bootstrap.c:61
static Form_pg_attribute AllocateAttribute(void)
Definition: bootstrap.c:916
#define NameStr(name)
Definition: c.h:751
#define DEBUG4
Definition: elog.h:27
i
int i
Definition: isn.c:77
#define NoLock
Definition: lockdefs.h:34
RangeVar * makeRangeVar(char *schemaname, char *relname, int location)
Definition: makefuncs.c:473
NameData relname
Definition: pg_class.h:38
#define NAMEDATALEN
#define RelationGetNumberOfAttributes(relation)
Definition: rel.h:520
TupleDesc rd_att
Definition: rel.h:112
Relation table_openrv(const RangeVar *relation, LOCKMODE lockmode)
Definition: table.c:83
static FormData_pg_attribute * TupleDescAttr(TupleDesc tupdesc, int i)
Definition: tupdesc.h:160

References AllocateAttribute(), ATTRIBUTE_FIXED_PART_SIZE, attrtypes, boot_reldesc, closerel(), DEBUG4, elog, i, makeRangeVar(), NAMEDATALEN, NameStr, NIL, NoLock, numattr, populate_typ_list(), RelationData::rd_att, RelationGetNumberOfAttributes, relname, table_openrv(), TupleDescAttr(), and Typ.

bootstrap_signals()

static void bootstrap_signals ( void  )
static

Definition at line 415 of file bootstrap.c.

416{
418
419 /*
420 * We don't actually need any non-default signal handling in bootstrap
421 * mode; "curl up and die" is a sufficient response for all these cases.
422 * Let's set that handling explicitly, as documentation if nothing else.
423 */
424 pqsignal(SIGHUP, SIG_DFL);
425 pqsignal(SIGINT, SIG_DFL);
426 pqsignal(SIGTERM, SIG_DFL);
427 pqsignal(SIGQUIT, SIG_DFL);
428}
bool IsUnderPostmaster
Definition: globals.c:120
Assert(PointerIsAligned(start, uint64))
#define pqsignal
Definition: port.h:531
#define SIGHUP
Definition: win32_port.h:158
#define SIGQUIT
Definition: win32_port.h:159

References Assert(), IsUnderPostmaster, pqsignal, SIGHUP, and SIGQUIT.

Referenced by BootstrapModeMain().

BootstrapModeMain()

void BootstrapModeMain ( int  argc,
char *  argv[],
bool  check_only 
)

Definition at line 200 of file bootstrap.c.

201{
202 int i;
203 char *progname = argv[0];
204 int flag;
205 char *userDoption = NULL;
206 uint32 bootstrap_data_checksum_version = 0; /* No checksum */
207 yyscan_t scanner;
208
210
211 InitStandaloneProcess(argv[0]);
212
213 /* Set defaults, to be overridden by explicit options below */
215
216 /* an initial --boot or --check should be present */
217 Assert(argc > 1
218 && (strcmp(argv[1], "--boot") == 0
219 || strcmp(argv[1], "--check") == 0));
220 argv++;
221 argc--;
222
223 while ((flag = getopt(argc, argv, "B:c:d:D:Fkr:X:-:")) != -1)
224 {
225 switch (flag)
226 {
227 case 'B':
228 SetConfigOption("shared_buffers", optarg, PGC_POSTMASTER, PGC_S_ARGV);
229 break;
230 case '-':
231
232 /*
233 * Error if the user misplaced a special must-be-first option
234 * for dispatching to a subprogram. parse_dispatch_option()
235 * returns DISPATCH_POSTMASTER if it doesn't find a match, so
236 * error for anything else.
237 */
240 (errcode(ERRCODE_SYNTAX_ERROR),
241 errmsg("--%s must be first argument", optarg)));
242
243 /* FALLTHROUGH */
244 case 'c':
245 {
246 char *name,
247 *value;
248
250 if (!value)
251 {
252 if (flag == '-')
254 (errcode(ERRCODE_SYNTAX_ERROR),
255 errmsg("--%s requires a value",
256 optarg)));
257 else
259 (errcode(ERRCODE_SYNTAX_ERROR),
260 errmsg("-c %s requires a value",
261 optarg)));
262 }
263
265 pfree(name);
266 pfree(value);
267 break;
268 }
269 case 'D':
271 break;
272 case 'd':
273 {
274 /* Turn on debugging for the bootstrap process. */
275 char *debugstr;
276
277 debugstr = psprintf("debug%s", optarg);
278 SetConfigOption("log_min_messages", debugstr,
280 SetConfigOption("client_min_messages", debugstr,
282 pfree(debugstr);
283 }
284 break;
285 case 'F':
286 SetConfigOption("fsync", "false", PGC_POSTMASTER, PGC_S_ARGV);
287 break;
288 case 'k':
289 bootstrap_data_checksum_version = PG_DATA_CHECKSUM_VERSION;
290 break;
291 case 'r':
293 break;
294 case 'X':
296 break;
297 default:
298 write_stderr("Try \"%s --help\" for more information.\n",
299 progname);
300 proc_exit(1);
301 break;
302 }
303 }
304
305 if (argc != optind)
306 {
307 write_stderr("%s: invalid command-line arguments\n", progname);
308 proc_exit(1);
309 }
310
311 /* Acquire configuration parameters */
313 proc_exit(1);
314
315 /*
316 * Validate we have been given a reasonable-looking DataDir and change
317 * into it
318 */
319 checkDataDir();
321
323
325 IgnoreSystemIndexes = true;
326
328
329 /*
330 * Even though bootstrapping runs in single-process mode, initialize
331 * postmaster child slots array so that --check can detect running out of
332 * shared memory or other resources if max_connections is set too high.
333 */
335
337
339
340 /*
341 * Estimate number of openable files. This is essential too in --check
342 * mode, because on some platforms semaphores count as open files.
343 */
345
346 /*
347 * XXX: It might make sense to move this into its own function at some
348 * point. Right now it seems like it'd cause more code duplication than
349 * it's worth.
350 */
351 if (check_only)
352 {
355 abort();
356 }
357
358 /*
359 * Do backend-like initialization for bootstrap mode
360 */
361 InitProcess();
362
363 BaseInit();
364
366 BootStrapXLOG(bootstrap_data_checksum_version);
367
368 /*
369 * To ensure that src/common/link-canary.c is linked into the backend, we
370 * must call it from somewhere. Here is as good as anywhere.
371 */
373 elog(ERROR, "backend is incorrectly linked to frontend functions");
374
375 InitPostgres(NULL, InvalidOid, NULL, InvalidOid, 0, NULL);
376
377 /* Initialize stuff for bootstrap-file processing */
378 for (i = 0; i < MAXATTR; i++)
379 {
380 attrtypes[i] = NULL;
381 Nulls[i] = false;
382 }
383
384 if (boot_yylex_init(&scanner) != 0)
385 elog(ERROR, "yylex_init() failed: %m");
386
387 /*
388 * Process bootstrap input.
389 */
391 boot_yyparse(scanner);
393
394 /*
395 * We should now know about all mapped relations, so it's okay to write
396 * out the initial relation mapping files.
397 */
399
400 /* Clean up and exit */
401 cleanup();
402 proc_exit(0);
403}
#define write_stderr(str)
Definition: parallel.c:186
static void CheckerModeMain(void)
Definition: bootstrap.c:182
static void cleanup(void)
Definition: bootstrap.c:715
static void bootstrap_signals(void)
Definition: bootstrap.c:415
static bool Nulls[MAXATTR]
Definition: bootstrap.c:154
int boot_yylex_init(yyscan_t *yyscannerp)
#define MAXATTR
Definition: bootstrap.h:25
int boot_yyparse(yyscan_t yyscanner)
#define PG_DATA_CHECKSUM_VERSION
Definition: bufpage.h:207
uint32_t uint32
Definition: c.h:538
void * yyscan_t
Definition: cubedata.h:65
int errcode(int sqlerrcode)
Definition: elog.c:854
int errmsg(const char *fmt,...)
Definition: elog.c:1071
#define ereport(elevel,...)
Definition: elog.h:150
void set_max_safe_fds(void)
Definition: fd.c:1041
char OutputFileName[MAXPGPATH]
Definition: globals.c:79
void SetConfigOption(const char *name, const char *value, GucContext context, GucSource source)
Definition: guc.c:4338
bool SelectConfigFiles(const char *userDoption, const char *progname)
Definition: guc.c:1786
void ParseLongOption(const char *string, char **name, char **value)
Definition: guc.c:6385
void InitializeGUCOptions(void)
Definition: guc.c:1532
@ PGC_S_DYNAMIC_DEFAULT
Definition: guc.h:114
@ PGC_S_ARGV
Definition: guc.h:117
@ PGC_INTERNAL
Definition: guc.h:73
@ PGC_POSTMASTER
Definition: guc.h:74
static struct @169 value
void proc_exit(int code)
Definition: ipc.c:104
void CreateSharedMemoryAndSemaphores(void)
Definition: ipci.c:200
DispatchOption parse_dispatch_option(const char *name)
Definition: main.c:244
const char * progname
Definition: main.c:44
char * pstrdup(const char *in)
Definition: mcxt.c:1759
void pfree(void *pointer)
Definition: mcxt.c:1594
@ NormalProcessing
Definition: miscadmin.h:471
@ BootstrapProcessing
Definition: miscadmin.h:469
#define SetProcessingMode(mode)
Definition: miscadmin.h:482
void ChangeToDataDir(void)
Definition: miscinit.c:409
void InitStandaloneProcess(const char *argv0)
Definition: miscinit.c:175
bool IgnoreSystemIndexes
Definition: miscinit.c:81
void checkDataDir(void)
Definition: miscinit.c:296
void CreateDataDirLockFile(bool amPostmaster)
Definition: miscinit.c:1463
#define MAXPGPATH
PGDLLIMPORT int optind
Definition: getopt.c:51
int getopt(int nargc, char *const *nargv, const char *ostr)
Definition: getopt.c:72
PGDLLIMPORT char * optarg
Definition: getopt.c:53
void InitPostmasterChildSlots(void)
Definition: pmchild.c:97
size_t strlcpy(char *dst, const char *src, size_t siz)
Definition: strlcpy.c:45
static const char * userDoption
Definition: postgres.c:153
#define InvalidOid
Definition: postgres_ext.h:37
void InitializeMaxBackends(void)
Definition: postinit.c:554
void BaseInit(void)
Definition: postinit.c:611
void InitializeFastPathLocks(void)
Definition: postinit.c:579
void InitPostgres(const char *in_dbname, Oid dboid, const char *username, Oid useroid, bits32 flags, char *out_dbname)
Definition: postinit.c:711
@ DISPATCH_POSTMASTER
Definition: postmaster.h:139
char * psprintf(const char *fmt,...)
Definition: psprintf.c:43
void RelationMapFinishBootstrap(void)
Definition: relmapper.c:625
void InitProcess(void)
Definition: proc.c:390
char * flag(int b)
Definition: test-ctype.c:33
const char * name
void StartTransactionCommand(void)
Definition: xact.c:3071
void CommitTransactionCommand(void)
Definition: xact.c:3169
void BootStrapXLOG(uint32 data_checksum_version)
Definition: xlog.c:5075

References Assert(), attrtypes, BaseInit(), boot_yylex_init(), boot_yyparse(), bootstrap_signals(), BootstrapProcessing, BootStrapXLOG(), ChangeToDataDir(), checkDataDir(), CheckerModeMain(), cleanup(), CommitTransactionCommand(), CreateDataDirLockFile(), CreateSharedMemoryAndSemaphores(), DISPATCH_POSTMASTER, elog, ereport, errcode(), errmsg(), ERROR, flag(), getopt(), i, IgnoreSystemIndexes, InitializeFastPathLocks(), InitializeGUCOptions(), InitializeMaxBackends(), InitPostgres(), InitPostmasterChildSlots(), InitProcess(), InitStandaloneProcess(), InvalidOid, IsUnderPostmaster, MAXATTR, MAXPGPATH, name, NormalProcessing, Nulls, optarg, optind, OutputFileName, parse_dispatch_option(), ParseLongOption(), pfree(), PG_DATA_CHECKSUM_VERSION, pg_link_canary_is_frontend(), PGC_INTERNAL, PGC_POSTMASTER, PGC_S_ARGV, PGC_S_DYNAMIC_DEFAULT, proc_exit(), progname, psprintf(), pstrdup(), RelationMapFinishBootstrap(), SelectConfigFiles(), set_max_safe_fds(), SetConfigOption(), SetProcessingMode, StartTransactionCommand(), strlcpy(), userDoption, value, and write_stderr.

Referenced by main().

build_indices()

void build_indices ( void  )

Definition at line 984 of file bootstrap.c.

985{
986 for (; ILHead != NULL; ILHead = ILHead->il_next)
987 {
988 Relation heap;
990
991 /* need not bother with locks during bootstrap */
994
995 index_build(heap, ind, ILHead->il_info, false, false);
996
998 table_close(heap, NoLock);
999 }
1000}
static IndexList * ILHead
Definition: bootstrap.c:172
void index_build(Relation heapRelation, Relation indexRelation, IndexInfo *indexInfo, bool isreindex, bool parallel)
Definition: index.c:3002
void index_close(Relation relation, LOCKMODE lockmode)
Definition: indexam.c:177
Relation index_open(Oid relationId, LOCKMODE lockmode)
Definition: indexam.c:133
Definition: rel.h:56
Oid il_heap
Definition: bootstrap.c:166
struct _IndexList * il_next
Definition: bootstrap.c:169
Oid il_ind
Definition: bootstrap.c:167
IndexInfo * il_info
Definition: bootstrap.c:168
void table_close(Relation relation, LOCKMODE lockmode)
Definition: table.c:126
Relation table_open(Oid relationId, LOCKMODE lockmode)
Definition: table.c:40

References _IndexList::il_heap, _IndexList::il_ind, _IndexList::il_info, _IndexList::il_next, ILHead, index_build(), index_close(), index_open(), NoLock, table_close(), and table_open().

CheckerModeMain()

static void CheckerModeMain ( void  )
static

Definition at line 182 of file bootstrap.c.

183{
184 proc_exit(0);
185}

References proc_exit().

Referenced by BootstrapModeMain().

cleanup()

static void cleanup ( void  )
static

Definition at line 715 of file bootstrap.c.

716{
717 if (boot_reldesc != NULL)
718 closerel(NULL);
719}

References boot_reldesc, and closerel().

Referenced by add_client_identification(), BootstrapModeMain(), conninfo_uri_parse_options(), GetConfFilesInDir(), getExtensions(), getPublications(), getSubscriptionTables(), handle_oauth_sasl_error(), main(), merge_list_bounds(), merge_range_bounds(), parse_oauth_json(), ParseConfigFile(), ParseConfigFp(), pg_GSS_read(), pg_GSS_write(), pg_regexec(), pgoutput_change(), print_aligned_text(), RecordTransactionCommit(), ReorderBufferRestoreChanges(), ResolveRecoveryConflictWithLock(), and validate().

closerel()

void closerel ( char *  relname )

Definition at line 487 of file bootstrap.c.

488{
489 if (relname)
490 {
491 if (boot_reldesc)
492 {
494 elog(ERROR, "close of %s when %s was expected",
496 }
497 else
498 elog(ERROR, "close of %s before any relation was opened",
499 relname);
500 }
501
502 if (boot_reldesc == NULL)
503 elog(ERROR, "no open relation to close");
504 else
505 {
506 elog(DEBUG4, "close relation %s",
509 boot_reldesc = NULL;
510 }
511}
#define RelationGetRelationName(relation)
Definition: rel.h:548

References boot_reldesc, DEBUG4, elog, ERROR, NoLock, RelationGetRelationName, relname, and table_close().

Referenced by boot_openrel(), cleanup(), and DefineAttr().

DefineAttr()

void DefineAttr ( char *  name,
char *  type,
int  attnum,
int  nullness 
)

Definition at line 524 of file bootstrap.c.

525{
526 Oid typeoid;
527
528 if (boot_reldesc != NULL)
529 {
530 elog(WARNING, "no open relations allowed with CREATE command");
531 closerel(NULL);
532 }
533
534 if (attrtypes[attnum] == NULL)
537
539 elog(DEBUG4, "column %s %s", NameStr(attrtypes[attnum]->attname), type);
540 attrtypes[attnum]->attnum = attnum + 1;
541
542 typeoid = gettype(type);
543
544 if (Typ != NIL)
545 {
546 attrtypes[attnum]->atttypid = Ap->am_oid;
547 attrtypes[attnum]->attlen = Ap->am_typ.typlen;
548 attrtypes[attnum]->attbyval = Ap->am_typ.typbyval;
549 attrtypes[attnum]->attalign = Ap->am_typ.typalign;
550 attrtypes[attnum]->attstorage = Ap->am_typ.typstorage;
551 attrtypes[attnum]->attcompression = InvalidCompressionMethod;
552 attrtypes[attnum]->attcollation = Ap->am_typ.typcollation;
553 /* if an array type, assume 1-dimensional attribute */
554 if (Ap->am_typ.typelem != InvalidOid && Ap->am_typ.typlen < 0)
555 attrtypes[attnum]->attndims = 1;
556 else
557 attrtypes[attnum]->attndims = 0;
558 }
559 else
560 {
561 attrtypes[attnum]->atttypid = TypInfo[typeoid].oid;
562 attrtypes[attnum]->attlen = TypInfo[typeoid].len;
563 attrtypes[attnum]->attbyval = TypInfo[typeoid].byval;
564 attrtypes[attnum]->attalign = TypInfo[typeoid].align;
565 attrtypes[attnum]->attstorage = TypInfo[typeoid].storage;
566 attrtypes[attnum]->attcompression = InvalidCompressionMethod;
567 attrtypes[attnum]->attcollation = TypInfo[typeoid].collation;
568 /* if an array type, assume 1-dimensional attribute */
569 if (TypInfo[typeoid].elem != InvalidOid &&
570 attrtypes[attnum]->attlen < 0)
571 attrtypes[attnum]->attndims = 1;
572 else
573 attrtypes[attnum]->attndims = 0;
574 }
575
576 /*
577 * If a system catalog column is collation-aware, force it to use C
578 * collation, so that its behavior is independent of the database's
579 * collation. This is essential to allow template0 to be cloned with a
580 * different database collation.
581 */
582 if (OidIsValid(attrtypes[attnum]->attcollation))
583 attrtypes[attnum]->attcollation = C_COLLATION_OID;
584
585 attrtypes[attnum]->atttypmod = -1;
586 attrtypes[attnum]->attislocal = true;
587
588 if (nullness == BOOTCOL_NULL_FORCE_NOT_NULL)
589 {
590 attrtypes[attnum]->attnotnull = true;
591 }
592 else if (nullness == BOOTCOL_NULL_FORCE_NULL)
593 {
594 attrtypes[attnum]->attnotnull = false;
595 }
596 else
597 {
598 Assert(nullness == BOOTCOL_NULL_AUTO);
599
600 /*
601 * Mark as "not null" if type is fixed-width and prior columns are
602 * likewise fixed-width and not-null. This corresponds to case where
603 * column can be accessed directly via C struct declaration.
604 */
605 if (attrtypes[attnum]->attlen > 0)
606 {
607 int i;
608
609 /* check earlier attributes */
610 for (i = 0; i < attnum; i++)
611 {
612 if (attrtypes[i]->attlen <= 0 ||
614 break;
615 }
616 if (i == attnum)
617 attrtypes[attnum]->attnotnull = true;
618 }
619 }
620}
static Oid gettype(char *type)
Definition: bootstrap.c:768
static struct typmap * Ap
Definition: bootstrap.c:151
#define BOOTCOL_NULL_FORCE_NULL
Definition: bootstrap.h:28
#define BOOTCOL_NULL_FORCE_NOT_NULL
Definition: bootstrap.h:29
#define BOOTCOL_NULL_AUTO
Definition: bootstrap.h:27
#define MemSet(start, val, len)
Definition: c.h:1019
#define WARNING
Definition: elog.h:36
void namestrcpy(Name name, const char *str)
Definition: name.c:233
NameData attname
Definition: pg_attribute.h:41
int16 attnum
Definition: pg_attribute.h:74
int16 attlen
Definition: pg_attribute.h:59
bool attnotnull
Definition: pg_attribute.h:123
unsigned int Oid
Definition: postgres_ext.h:32
Oid oid
Definition: bootstrap.c:76
Oid collation
Definition: bootstrap.c:82
char storage
Definition: bootstrap.c:81
#define InvalidCompressionMethod
const char * type

References typinfo::align, AllocateAttribute(), typmap::am_oid, typmap::am_typ, Ap, Assert(), attlen, attname, attnotnull, attnum, ATTRIBUTE_FIXED_PART_SIZE, attrtypes, boot_reldesc, BOOTCOL_NULL_AUTO, BOOTCOL_NULL_FORCE_NOT_NULL, BOOTCOL_NULL_FORCE_NULL, typinfo::byval, closerel(), typinfo::collation, DEBUG4, elog, gettype(), i, InvalidCompressionMethod, InvalidOid, typinfo::len, MemSet, name, NameStr, namestrcpy(), NIL, typinfo::oid, OidIsValid, typinfo::storage, Typ, type, TypInfo, and WARNING.

gettype()

static Oid gettype ( char *  type )
static

Definition at line 768 of file bootstrap.c.

769{
770 if (Typ != NIL)
771 {
772 ListCell *lc;
773
774 foreach(lc, Typ)
775 {
776 struct typmap *app = lfirst(lc);
777
778 if (strncmp(NameStr(app->am_typ.typname), type, NAMEDATALEN) == 0)
779 {
780 Ap = app;
781 return app->am_oid;
782 }
783 }
784
785 /*
786 * The type wasn't known; reload the pg_type contents and check again
787 * to handle composite types, added since last populating the list.
788 */
789
791 Typ = NIL;
793
794 /*
795 * Calling gettype would result in infinite recursion for types
796 * missing in pg_type, so just repeat the lookup.
797 */
798 foreach(lc, Typ)
799 {
800 struct typmap *app = lfirst(lc);
801
802 if (strncmp(NameStr(app->am_typ.typname), type, NAMEDATALEN) == 0)
803 {
804 Ap = app;
805 return app->am_oid;
806 }
807 }
808 }
809 else
810 {
811 int i;
812
813 for (i = 0; i < n_types; i++)
814 {
815 if (strncmp(type, TypInfo[i].name, NAMEDATALEN) == 0)
816 return i;
817 }
818 /* Not in TypInfo, so we'd better be able to read pg_type now */
819 elog(DEBUG4, "external type: %s", type);
821 return gettype(type);
822 }
823 elog(ERROR, "unrecognized type \"%s\"", type);
824 /* not reached, here to make compiler happy */
825 return 0;
826}
void list_free_deep(List *list)
Definition: list.c:1560

References typmap::am_oid, typmap::am_typ, Ap, DEBUG4, elog, ERROR, gettype(), i, lfirst, list_free_deep(), n_types, name, NAMEDATALEN, NameStr, NIL, populate_typ_list(), Typ, type, and TypInfo.

Referenced by DefineAttr(), and gettype().

index_register()

void index_register ( Oid  heap,
Oid  ind,
const IndexInfoindexInfo 
)

Definition at line 934 of file bootstrap.c.

937{
938 IndexList *newind;
939 MemoryContext oldcxt;
940
941 /*
942 * XXX mao 10/31/92 -- don't gc index reldescs, associated info at
943 * bootstrap time. we'll declare the indexes now, but want to create them
944 * later.
945 */
946
947 if (nogc == NULL)
949 "BootstrapNoGC",
951
952 oldcxt = MemoryContextSwitchTo(nogc);
953
954 newind = (IndexList *) palloc(sizeof(IndexList));
955 newind->il_heap = heap;
956 newind->il_ind = ind;
957 newind->il_info = (IndexInfo *) palloc(sizeof(IndexInfo));
958
959 memcpy(newind->il_info, indexInfo, sizeof(IndexInfo));
960 /* expressions will likely be null, but may as well copy it */
961 newind->il_info->ii_Expressions =
962 copyObject(indexInfo->ii_Expressions);
964 /* predicate will likely be null, but may as well copy it */
965 newind->il_info->ii_Predicate =
966 copyObject(indexInfo->ii_Predicate);
967 newind->il_info->ii_PredicateState = NULL;
968 /* no exclusion constraints at bootstrap time, so no need to copy */
969 Assert(indexInfo->ii_ExclusionOps == NULL);
970 Assert(indexInfo->ii_ExclusionProcs == NULL);
971 Assert(indexInfo->ii_ExclusionStrats == NULL);
972
973 newind->il_next = ILHead;
974 ILHead = newind;
975
976 MemoryContextSwitchTo(oldcxt);
977}
static MemoryContext nogc
Definition: bootstrap.c:156
void * palloc(Size size)
Definition: mcxt.c:1365
#define AllocSetContextCreate
Definition: memutils.h:129
#define ALLOCSET_DEFAULT_SIZES
Definition: memutils.h:160
#define copyObject(obj)
Definition: nodes.h:232
static MemoryContext MemoryContextSwitchTo(MemoryContext context)
Definition: palloc.h:124
uint16 * ii_ExclusionStrats
Definition: execnodes.h:192
ExprState * ii_PredicateState
Definition: execnodes.h:185
Oid * ii_ExclusionOps
Definition: execnodes.h:188
List * ii_ExpressionsState
Definition: execnodes.h:180
List * ii_Expressions
Definition: execnodes.h:178
Oid * ii_ExclusionProcs
Definition: execnodes.h:190
List * ii_Predicate
Definition: execnodes.h:183

References ALLOCSET_DEFAULT_SIZES, AllocSetContextCreate, Assert(), copyObject, IndexInfo::ii_ExclusionOps, IndexInfo::ii_ExclusionProcs, IndexInfo::ii_ExclusionStrats, IndexInfo::ii_Expressions, IndexInfo::ii_ExpressionsState, IndexInfo::ii_Predicate, IndexInfo::ii_PredicateState, _IndexList::il_heap, _IndexList::il_ind, _IndexList::il_info, _IndexList::il_next, ILHead, MemoryContextSwitchTo(), NIL, nogc, and palloc().

Referenced by index_create().

InsertOneNull()

void InsertOneNull ( int  i )

Definition at line 697 of file bootstrap.c.

698{
699 elog(DEBUG4, "inserting column %d NULL", i);
700 Assert(i >= 0 && i < MAXATTR);
701 if (TupleDescAttr(boot_reldesc->rd_att, i)->attnotnull)
702 elog(ERROR,
703 "NULL value specified for not-null column \"%s\" of relation \"%s\"",
706 values[i] = PointerGetDatum(NULL);
707 Nulls[i] = true;
708}
static Datum values[MAXATTR]
Definition: bootstrap.c:153
static Datum PointerGetDatum(const void *X)
Definition: postgres.h:332

References Assert(), boot_reldesc, DEBUG4, elog, ERROR, i, MAXATTR, NameStr, Nulls, PointerGetDatum(), RelationData::rd_att, RelationGetRelationName, TupleDescAttr(), and values.

InsertOneTuple()

void InsertOneTuple ( void  )

Definition at line 631 of file bootstrap.c.

632{
633 HeapTuple tuple;
634 TupleDesc tupDesc;
635 int i;
636
637 elog(DEBUG4, "inserting row with %d columns", numattr);
638
640 tuple = heap_form_tuple(tupDesc, values, Nulls);
641 pfree(tupDesc); /* just free's tupDesc, not the attrtypes */
642
644 heap_freetuple(tuple);
645 elog(DEBUG4, "row inserted");
646
647 /*
648 * Reset null markers for next tuple
649 */
650 for (i = 0; i < numattr; i++)
651 Nulls[i] = false;
652}
void simple_heap_insert(Relation relation, HeapTuple tup)
Definition: heapam.c:2720
HeapTuple heap_form_tuple(TupleDesc tupleDescriptor, const Datum *values, const bool *isnull)
Definition: heaptuple.c:1117
void heap_freetuple(HeapTuple htup)
Definition: heaptuple.c:1435
TupleDesc CreateTupleDesc(int natts, Form_pg_attribute *attrs)
Definition: tupdesc.c:229

References attrtypes, boot_reldesc, CreateTupleDesc(), DEBUG4, elog, heap_form_tuple(), heap_freetuple(), i, Nulls, numattr, pfree(), simple_heap_insert(), and values.

InsertOneValue()

void InsertOneValue ( char *  value,
int  i 
)

Definition at line 659 of file bootstrap.c.

660{
661 Oid typoid;
662 int16 typlen;
663 bool typbyval;
664 char typalign;
665 char typdelim;
666 Oid typioparam;
667 Oid typinput;
668 Oid typoutput;
669
670 Assert(i >= 0 && i < MAXATTR);
671
672 elog(DEBUG4, "inserting column %d value \"%s\"", i, value);
673
674 typoid = TupleDescAttr(boot_reldesc->rd_att, i)->atttypid;
675
677 &typlen, &typbyval, &typalign,
678 &typdelim, &typioparam,
679 &typinput, &typoutput);
680
681 values[i] = OidInputFunctionCall(typinput, value, typioparam, -1);
682
683 /*
684 * We use ereport not elog here so that parameters aren't evaluated unless
685 * the message is going to be printed, which generally it isn't
686 */
688 (errmsg_internal("inserted -> %s",
689 OidOutputFunctionCall(typoutput, values[i]))));
690}
void boot_get_type_io_data(Oid typid, int16 *typlen, bool *typbyval, char *typalign, char *typdelim, Oid *typioparam, Oid *typinput, Oid *typoutput)
Definition: bootstrap.c:839
int16_t int16
Definition: c.h:533
int errmsg_internal(const char *fmt,...)
Definition: elog.c:1161
Datum OidInputFunctionCall(Oid functionId, char *str, Oid typioparam, int32 typmod)
Definition: fmgr.c:1754
char * OidOutputFunctionCall(Oid functionId, Datum val)
Definition: fmgr.c:1763

References Assert(), boot_get_type_io_data(), boot_reldesc, DEBUG4, elog, ereport, errmsg_internal(), i, MAXATTR, OidInputFunctionCall(), OidOutputFunctionCall(), RelationData::rd_att, TupleDescAttr(), typalign, value, and values.

populate_typ_list()

static void populate_typ_list ( void  )
static

Definition at line 728 of file bootstrap.c.

729{
730 Relation rel;
731 TableScanDesc scan;
732 HeapTuple tup;
733 MemoryContext old;
734
735 Assert(Typ == NIL);
736
737 rel = table_open(TypeRelationId, NoLock);
738 scan = table_beginscan_catalog(rel, 0, NULL);
740 while ((tup = heap_getnext(scan, ForwardScanDirection)) != NULL)
741 {
742 Form_pg_type typForm = (Form_pg_type) GETSTRUCT(tup);
743 struct typmap *newtyp;
744
745 newtyp = (struct typmap *) palloc(sizeof(struct typmap));
746 Typ = lappend(Typ, newtyp);
747
748 newtyp->am_oid = typForm->oid;
749 memcpy(&newtyp->am_typ, typForm, sizeof(newtyp->am_typ));
750 }
752 table_endscan(scan);
753 table_close(rel, NoLock);
754}
HeapTuple heap_getnext(TableScanDesc sscan, ScanDirection direction)
Definition: heapam.c:1346
static void * GETSTRUCT(const HeapTupleData *tuple)
Definition: htup_details.h:728
List * lappend(List *list, void *datum)
Definition: list.c:339
FormData_pg_type * Form_pg_type
Definition: pg_type.h:261
@ ForwardScanDirection
Definition: sdir.h:28
TableScanDesc table_beginscan_catalog(Relation relation, int nkeys, ScanKeyData *key)
Definition: tableam.c:113
static void table_endscan(TableScanDesc scan)
Definition: tableam.h:985

References typmap::am_oid, typmap::am_typ, Assert(), ForwardScanDirection, GETSTRUCT(), heap_getnext(), lappend(), MemoryContextSwitchTo(), NIL, NoLock, palloc(), table_beginscan_catalog(), table_close(), table_endscan(), table_open(), TopMemoryContext, and Typ.

Referenced by boot_openrel(), and gettype().

Variable Documentation

Ap

struct typmap* Ap = NULL
static

Definition at line 151 of file bootstrap.c.

Referenced by DefineAttr(), and gettype().

attrtypes

Definition at line 60 of file bootstrap.c.

Referenced by boot_openrel(), BootstrapModeMain(), DefineAttr(), and InsertOneTuple().

boot_reldesc

Relation boot_reldesc

Definition at line 58 of file bootstrap.c.

Referenced by boot_openrel(), cleanup(), closerel(), DefineAttr(), InsertOneNull(), InsertOneTuple(), and InsertOneValue().

ILHead

IndexList* ILHead = NULL
static

Definition at line 172 of file bootstrap.c.

Referenced by build_indices(), and index_register().

n_types

const int n_types = sizeof(TypInfo) / sizeof(struct typinfo)
static

Definition at line 142 of file bootstrap.c.

Referenced by boot_get_type_io_data(), and gettype().

nogc

MemoryContext nogc = NULL
static

Definition at line 156 of file bootstrap.c.

Referenced by index_register().

Nulls

bool Nulls[MAXATTR]
static

Definition at line 154 of file bootstrap.c.

Referenced by _SPI_convert_params(), BootstrapModeMain(), InsertOneNull(), InsertOneTuple(), SPI_cursor_open(), SPI_cursor_open_with_args(), SPI_execp(), SPI_execute_plan(), SPI_execute_snapshot(), SPI_execute_with_args(), and SPI_modifytuple().

numattr

int numattr

Definition at line 61 of file bootstrap.c.

Referenced by boot_openrel(), InsertOneTuple(), and tsvector_update_trigger().

Typ

List* Typ = NIL
static

Definition at line 150 of file bootstrap.c.

Referenced by boot_get_type_io_data(), boot_openrel(), DefineAttr(), gettype(), and populate_typ_list().

TypInfo

const struct typinfo TypInfo[]
static

Definition at line 87 of file bootstrap.c.

Referenced by boot_get_type_io_data(), DefineAttr(), and gettype().

values

Datum values[MAXATTR]
static

Definition at line 153 of file bootstrap.c.

Referenced by _bt_build_callback(), _bt_check_unique(), _bt_spool(), _h_spool(), aclexplode(), add_values_to_range(), AddEnumLabel(), AddSubscriptionRelState(), AggregateCreate(), AlterCollation(), AlterDatabaseRefreshColl(), AlterObjectNamespace_internal(), AlterObjectOwner_internal(), AlterObjectRename_internal(), AlterOperator(), AlterPolicy(), AlterPublicationOptions(), AlterSetting(), AlterSubscription(), AlterTypeRecurse(), apply_returning_filter(), ApplyExtensionUpdates(), array_in(), array_iterate(), array_map(), array_out(), array_replace_internal(), attribute_statistics_update(), blinsert(), bloomBuildCallback(), BloomFormTuple(), brin_deconstruct_tuple(), brin_deform_tuple(), brin_form_tuple(), brin_metapage_info(), brin_page_items(), brinbuildCallback(), brinbuildCallbackParallel(), brininsert(), bt_metap(), bt_multi_page_stats(), bt_page_print_tuples(), bt_page_stats_internal(), bt_tuple_present_callback(), btinsert(), build_index_value_desc(), build_pgstattuple_type(), build_sorted_items(), build_tuplestore_recursively(), BuildIndexValueDescription(), BuildTupleFromCStrings(), CastCreate(), CatalogIndexInsert(), check_conn_params(), check_exclusion_constraint(), check_exclusion_or_unique_constraint(), clear_subscription_skip_lsn(), CollationCreate(), collectTSQueryValues(), comparetup_index_btree_tiebreak(), compute_index_stats(), compute_partition_hash_value(), compute_scalar_stats(), connect_pg_server(), ConnectDatabase(), connectDatabase(), conninfo_array_parse(), constructConnStr(), ConversionCreate(), convert_VALUES_to_ANY(), copy_replication_slot(), CopyArrayEls(), CopyFromBinaryOneRow(), CopyFromCSVOneRow(), CopyFromTextLikeOneRow(), CopyFromTextOneRow(), create_cursor(), CreateAccessMethod(), CreateComments(), CreateConstraintEntry(), CreateForeignDataWrapper(), CreateForeignServer(), CreateForeignTable(), CreateOpFamily(), CreatePolicy(), CreateProceduralLanguage(), CreatePublication(), CreateReplicationSlot(), CreateSharedComments(), CreateStatistics(), CreateSubscription(), CreateTableSpace(), CreateTransform(), CreateTriggerFiringOn(), CreateUserMapping(), crosstab(), dblink_get_notify(), dblink_get_pkey(), DefineOpClass(), DefineTSConfiguration(), DefineTSDictionary(), DefineTSParser(), DefineTSTemplate(), DisableSubscription(), DiscreteKnapsack(), do_connect(), do_text_output_multiline(), do_tup_output(), doConnect(), each_object_field_end(), each_worker_jsonb(), elements_array_element_end(), elements_worker_jsonb(), exec_move_row(), exec_move_row_from_fields(), ExecBuildAggTrans(), ExecBuildSlotPartitionKeyDescription(), ExecCheckIndexConstraints(), ExecComputeStoredGenerated(), ExecEvalMinMax(), ExecEvalXmlExpr(), ExecFilterJunk(), ExecFindPartition(), ExecGrant_Attribute(), ExecGrant_common(), ExecGrant_Largeobject(), ExecGrant_Parameter(), ExecGrant_Relation(), ExecInitExprRec(), ExecInsertIndexTuples(), execute_dml_stmt(), ExtractConnectionOptions(), ExtractReplicaIdentity(), file_acquire_sample_rows(), fill_hba_line(), fill_ident_line(), fillRelOptions(), FillXLogStatsRow(), FormIndexDatum(), FormPartitionKeyDatum(), get_actual_variable_endpoint(), get_altertable_subcmdinfo(), get_available_versions_for_extension(), get_crosstab_tuplestore(), get_matching_hash_bounds(), get_matching_range_bounds(), get_partition_for_tuple(), get_text_array_contents(), GetConfigOptionValues(), GetConnection(), GetWALBlockInfo(), GetWALRecordInfo(), GetWALRecordsInfo(), GetWalStats(), GetXLogSummaryStats(), gin_leafpage_items(), gin_metapage_info(), gin_page_opaque_info(), ginBuildCallback(), ginBuildCallbackParallel(), gininsert(), gist_page_items(), gist_page_items_bytea(), gist_page_opaque_info(), gistBuildCallback(), gistinsert(), gistSortedBuildCallback(), hash_bitmap_info(), hash_metapage_info(), hash_page_items(), hash_page_stats(), hash_record(), hash_record_extended(), hashbuildCallback(), hashinsert(), heap_compute_data_size(), heap_deform_tuple(), heap_fill_tuple(), heap_form_minimal_tuple(), heap_form_tuple(), heap_modify_tuple(), heap_modify_tuple_by_cols(), heap_page_items(), heap_tuple_infomask_flags(), heapam_index_build_range_scan(), heapam_index_validate_scan(), heapam_relation_copy_for_cluster(), hstore_from_record(), hstore_populate_record(), IdentifySystem(), index_concurrently_swap(), index_deform_tuple(), index_deform_tuple_internal(), index_form_tuple(), index_form_tuple_context(), index_insert(), index_truncate_tuple(), IndexCheckExclusion(), inet_hist_value_sel(), init_empty_stats_tuple(), injection_points_list(), injection_points_stats_fixed(), insert_event_trigger_tuple(), InsertExtensionTuple(), InsertOneNull(), InsertOneTuple(), InsertOneValue(), InsertPgClassTuple(), InsertRule(), intset_flush_buffered_values(), inv_truncate(), inv_write(), LargeObjectCreate(), libpqsrv_connect_params(), LogicalOutputWrite(), logicalrep_write_tuple(), main(), make_tuple_from_result_row(), make_tuple_indirect(), materializeQueryResult(), materializeResult(), minmax_multi_init(), NamespaceCreate(), ndistinct_for_combination(), NextCopyFrom(), oid_array_to_list(), OperatorCreate(), OperatorShellMake(), page_header(), ParameterAclCreate(), parse_key_value_arrays(), parseLocalRelOptions(), partition_range_datum_bsearch(), perform_pruning_base_step(), pg_armor(), pg_available_extensions(), pg_available_wal_summaries(), pg_backup_stop(), pg_buffercache_evict(), pg_buffercache_evict_all(), pg_buffercache_evict_relation(), pg_buffercache_numa_pages(), pg_buffercache_pages(), pg_buffercache_summary(), pg_config(), pg_control_checkpoint(), pg_control_init(), pg_control_recovery(), pg_control_system(), pg_create_logical_replication_slot(), pg_create_physical_replication_slot(), pg_cursor(), pg_event_trigger_ddl_commands(), pg_event_trigger_dropped_objects(), pg_extension_update_paths(), pg_get_aios(), pg_get_catalog_foreign_keys(), pg_get_keywords(), pg_get_loaded_modules(), pg_get_logical_snapshot_info(), pg_get_logical_snapshot_meta(), pg_get_multixact_members(), pg_get_object_address(), pg_get_publication_tables(), pg_get_replication_slots(), pg_get_sequence_data(), pg_get_shmem_allocations(), pg_get_shmem_allocations_numa(), pg_get_wait_events(), pg_get_wal_record_info(), pg_get_wal_resource_managers(), pg_get_wal_summarizer_state(), pg_identify_object(), pg_identify_object_as_address(), pg_input_error_info(), pg_last_committed_xact(), pg_lock_status(), pg_ls_dir(), pg_ls_dir_files(), pg_options_to_table(), pg_partition_tree(), pg_prepared_statement(), pg_prepared_xact(), pg_replication_slot_advance(), pg_sequence_parameters(), pg_show_replication_origin_status(), pg_split_walfile_name(), pg_stat_file(), pg_stat_get_activity(), pg_stat_get_archiver(), pg_stat_get_backend_subxact(), pg_stat_get_progress_info(), pg_stat_get_recovery_prefetch(), pg_stat_get_replication_slot(), pg_stat_get_slru(), pg_stat_get_subscription(), pg_stat_get_subscription_stats(), pg_stat_get_wal_receiver(), pg_stat_get_wal_senders(), pg_stat_io_build_tuples(), pg_stat_statements_info(), pg_stat_statements_internal(), pg_stat_wal_build_tuple(), pg_stats_ext_mcvlist_items(), pg_tablespace_databases(), pg_timezone_abbrevs_abbrevs(), pg_timezone_abbrevs_zone(), pg_timezone_names(), pg_visibility(), pg_visibility_map(), pg_visibility_map_rel(), pg_visibility_map_summary(), pg_visibility_rel(), pg_wal_summary_contents(), pg_walfile_name_offset(), pg_xact_commit_timestamp_origin(), pgfdw_has_required_scram_options(), pgfdw_security_check(), pgp_armor_encode(), pgp_armor_headers(), pgp_extract_armor_headers(), pgrowlocks(), pgstatginindex_internal(), pgstathashindex(), pgstatindex_impl(), pgstattuple_approx_internal(), plperl_build_tuple_result(), pltcl_build_tuple_result(), PLy_cursor_plan(), PLy_spi_execute_plan(), PLyGenericObject_ToComposite(), PLyMapping_ToComposite(), PLySequence_ToComposite(), populate_record(), postgres_fdw_get_connections_internal(), PQconnectdbParams(), PQconnectStartParams(), PQpingParams(), ProcedureCreate(), prs_process_call(), publication_add_relation(), publication_add_schema(), PutMemoryContextsStatsTupleStore(), RangeCreate(), ReadArrayBinary(), ReadArrayStr(), ReadReplicationSlot(), record_in(), record_out(), record_recv(), record_send(), recordExtensionInitPrivWorker(), reduce_expanded_ranges(), reform_and_rewrite_tuple(), regression_main(), relation_statistics_update(), RemoveRoleFromInitPriv(), RemoveRoleFromObjectPolicy(), ReplaceRoleInInitPriv(), replorigin_create(), report_corruption_internal(), SendTablespaceList(), SendXlogRecPtrResult(), serialize_expr_stats(), set_stats_slot(), SetDefaultACL(), SetSecurityLabel(), SetSharedSecurityLabel(), shdepAddDependency(), shdepChangeDep(), show_all_file_settings(), show_all_settings(), ShowAllGUCConfig(), slot_deform_heap_tuple_internal(), spginsert(), spgistBuildCallback(), split_text_accum_result(), sql_conn(), ssl_extension_info(), StartReplication(), statext_mcv_serialize(), statext_store(), StoreAttrDefault(), storeOperators(), StorePartitionKey(), storeProcedures(), StoreSingleInheritance(), test_enc_conversion(), test_huge_distances(), test_predtest(), tfuncLoadRows(), toast_build_flattened_tuple(), toast_delete_external(), TransformGUCArray(), ts_process_call(), tsvector_unnest(), tt_process_call(), tuplesort_putindextuplevalues(), tuplestore_putvalues(), TypeCreate(), TypeShellMake(), unique_key_recheck(), update_attstats(), UpdateDeadTupleRetentionStatus(), UpdateIndexRelation(), UpdateSubscriptionRelState(), UpdateTwoPhaseState(), upsert_pg_statistic(), vacuumlo(), ValuesNext(), WaitForLockersMultiple(), and xpath_table().

AltStyle によって変換されたページ (->オリジナル) /