PostgreSQL Source Code git master
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
elog.c File Reference
#include "postgres.h"
#include <fcntl.h>
#include <time.h>
#include <unistd.h>
#include <signal.h>
#include <ctype.h>
#include "access/xact.h"
#include "common/ip.h"
#include "libpq/libpq.h"
#include "libpq/pqformat.h"
#include "mb/pg_wchar.h"
#include "miscadmin.h"
#include "nodes/miscnodes.h"
#include "pgstat.h"
#include "postmaster/bgworker.h"
#include "postmaster/postmaster.h"
#include "postmaster/syslogger.h"
#include "storage/ipc.h"
#include "storage/proc.h"
#include "tcop/tcopprot.h"
#include "utils/guc_hooks.h"
#include "utils/memutils.h"
#include "utils/ps_status.h"
#include "utils/varlena.h"
Include dependency graph for elog.c:

Go to the source code of this file.

Macros

#define _(x)   err_gettext(x)
 
#define ERRORDATA_STACK_SIZE   5
 
#define FORMATTED_TS_LEN   128
 
#define CHECK_STACK_DEPTH()
 
#define EVALUATE_MESSAGE(domain, targetfield, appendval, translateit)
 
#define EVALUATE_MESSAGE_PLURAL(domain, targetfield, appendval)
 

Functions

static const char * err_gettext (const char *str) pg_attribute_format_arg(1)
 
static ErrorDataget_error_stack_entry (void)
 
static void set_stack_entry_domain (ErrorData *edata, const char *domain)
 
static void set_stack_entry_location (ErrorData *edata, const char *filename, int lineno, const char *funcname)
 
static bool matches_backtrace_functions (const char *funcname)
 
static pg_noinline void set_backtrace (ErrorData *edata, int num_skip)
 
static void set_errdata_field (MemoryContextData *cxt, char **ptr, const char *str)
 
static void FreeErrorDataContents (ErrorData *edata)
 
static void write_console (const char *line, int len)
 
static const char * process_log_prefix_padding (const char *p, int *ppadding)
 
static void log_line_prefix (StringInfo buf, ErrorData *edata)
 
static void send_message_to_server_log (ErrorData *edata)
 
static void send_message_to_frontend (ErrorData *edata)
 
static void append_with_tabs (StringInfo buf, const char *str)
 
static bool is_log_level_output (int elevel, int log_min_level)
 
static bool should_output_to_server (int elevel)
 
static bool should_output_to_client (int elevel)
 
bool message_level_is_interesting (int elevel)
 
bool in_error_recursion_trouble (void)
 
pg_attribute_cold bool errstart_cold (int elevel, const char *domain)
 
bool errstart (int elevel, const char *domain)
 
void errfinish (const char *filename, int lineno, const char *funcname)
 
bool errsave_start (struct Node *context, const char *domain)
 
void errsave_finish (struct Node *context, const char *filename, int lineno, const char *funcname)
 
int errcode (int sqlerrcode)
 
int errcode_for_file_access (void)
 
int errcode_for_socket_access (void)
 
int errmsg (const char *fmt,...)
 
int errbacktrace (void)
 
int errmsg_internal (const char *fmt,...)
 
int errmsg_plural (const char *fmt_singular, const char *fmt_plural, unsigned long n,...)
 
int errdetail (const char *fmt,...)
 
int errdetail_internal (const char *fmt,...)
 
int errdetail_log (const char *fmt,...)
 
int errdetail_log_plural (const char *fmt_singular, const char *fmt_plural, unsigned long n,...)
 
int errdetail_plural (const char *fmt_singular, const char *fmt_plural, unsigned long n,...)
 
int errhint (const char *fmt,...)
 
int errhint_internal (const char *fmt,...)
 
int errhint_plural (const char *fmt_singular, const char *fmt_plural, unsigned long n,...)
 
int errcontext_msg (const char *fmt,...)
 
int set_errcontext_domain (const char *domain)
 
int errhidestmt (bool hide_stmt)
 
int errhidecontext (bool hide_ctx)
 
int errposition (int cursorpos)
 
int internalerrposition (int cursorpos)
 
int internalerrquery (const char *query)
 
int err_generic_string (int field, const char *str)
 
int geterrcode (void)
 
int geterrlevel (void)
 
int geterrposition (void)
 
int getinternalerrposition (void)
 
void pre_format_elog_string (int errnumber, const char *domain)
 
char * format_elog_string (const char *fmt,...)
 
void EmitErrorReport (void)
 
ErrorDataCopyErrorData (void)
 
void FreeErrorData (ErrorData *edata)
 
void FlushErrorState (void)
 
void ThrowErrorData (ErrorData *edata)
 
void ReThrowError (ErrorData *edata)
 
void pg_re_throw (void)
 
char * GetErrorContextStack (void)
 
void DebugFileOpen (void)
 
bool check_backtrace_functions (char **newval, void **extra, GucSource source)
 
void assign_backtrace_functions (const char *newval, void *extra)
 
bool check_log_destination (char **newval, void **extra, GucSource source)
 
void assign_log_destination (const char *newval, void *extra)
 
void assign_syslog_ident (const char *newval, void *extra)
 
void assign_syslog_facility (int newval, void *extra)
 
char * get_formatted_log_time (void)
 
void reset_formatted_start_time (void)
 
char * get_formatted_start_time (void)
 
bool check_log_of_query (ErrorData *edata)
 
const char * get_backend_type_for_log (void)
 
void log_status_format (StringInfo buf, const char *format, ErrorData *edata)
 
char * unpack_sql_state (int sql_state)
 
void write_pipe_chunks (char *data, int len, int dest)
 
static void err_sendstring (StringInfo buf, const char *str)
 
const char * error_severity (int elevel)
 
void write_stderr (const char *fmt,...)
 

Variables

ErrorContextCallbackerror_context_stack = NULL
 
sigjmp_buf * PG_exception_stack = NULL
 
emit_log_hook_type emit_log_hook = NULL
 
int Log_error_verbosity = PGERROR_DEFAULT
 
char * Log_line_prefix = NULL
 
int Log_destination = LOG_DESTINATION_STDERR
 
char * Log_destination_string = NULL
 
bool syslog_sequence_numbers = true
 
bool syslog_split_messages = true
 
static char * backtrace_function_list
 
static ErrorData errordata [ERRORDATA_STACK_SIZE]
 
static int errordata_stack_depth = -1
 
static int recursion_depth = 0
 
static struct timeval saved_timeval
 
static bool saved_timeval_set = false
 
static char formatted_start_time [FORMATTED_TS_LEN]
 
static char formatted_log_time [FORMATTED_TS_LEN]
 
static int save_format_errnumber
 
static const char * save_format_domain
 

Macro Definition Documentation

◆ _

#define _ (   x)    err_gettext(x)

Definition at line 91 of file elog.c.

◆ CHECK_STACK_DEPTH

#define CHECK_STACK_DEPTH ( )
Value:
do { \
{ \
errordata_stack_depth = -1; \
ereport(ERROR, (errmsg_internal("errstart was not called"))); \
} \
} while (0)
int errmsg_internal(const char *fmt,...)
Definition: elog.c:1158
static int errordata_stack_depth
Definition: elog.c:148
#define ERROR
Definition: elog.h:39

Definition at line 165 of file elog.c.

◆ ERRORDATA_STACK_SIZE

#define ERRORDATA_STACK_SIZE   5

Definition at line 144 of file elog.c.

◆ EVALUATE_MESSAGE

#define EVALUATE_MESSAGE (   domain,
  targetfield,
  appendval,
  translateit 
)
Value:
{ \
StringInfoData buf; \
/* Internationalize the error format string */ \
if ((translateit) && !in_error_recursion_trouble()) \
fmt = dgettext((domain), fmt); \
initStringInfo(&buf); \
if ((appendval) && edata->targetfield) { \
appendStringInfoString(&buf, edata->targetfield); \
appendStringInfoChar(&buf, '\n'); \
} \
/* Generate actual output --- have to use appendStringInfoVA */ \
for (;;) \
{ \
va_list args; \
int needed; \
errno = edata->saved_errno; \
va_start(args, fmt); \
needed = appendStringInfoVA(&buf, fmt, args); \
va_end(args); \
if (needed == 0) \
break; \
enlargeStringInfo(&buf, needed); \
} \
/* Save the completed message into the stack item */ \
if (edata->targetfield) \
pfree(edata->targetfield); \
edata->targetfield = pstrdup(buf.data); \
pfree(buf.data); \
}
#define dgettext(d, x)
Definition: c.h:1151
bool in_error_recursion_trouble(void)
Definition: elog.c:294
char * pstrdup(const char *in)
Definition: mcxt.c:1699
static char * buf
Definition: pg_test_fsync.c:72
int appendStringInfoVA(StringInfo str, const char *fmt, va_list args)
Definition: stringinfo.c:187

Definition at line 990 of file elog.c.

◆ EVALUATE_MESSAGE_PLURAL

#define EVALUATE_MESSAGE_PLURAL (   domain,
  targetfield,
  appendval 
)

Definition at line 1026 of file elog.c.

◆ FORMATTED_TS_LEN

#define FORMATTED_TS_LEN   128

Definition at line 159 of file elog.c.

Function Documentation

◆ append_with_tabs()

static void append_with_tabs ( StringInfo  buf,
const char *  str 
)
static

Definition at line 3780 of file elog.c.

3781{
3782 char ch;
3783
3784 while ((ch = *str++) != '\0')
3785 {
3787 if (ch == '\n')
3789 }
3790}
const char * str
#define appendStringInfoCharMacro(str, ch)
Definition: stringinfo.h:231

References appendStringInfoCharMacro, buf, and str.

Referenced by send_message_to_server_log().

◆ assign_backtrace_functions()

void assign_backtrace_functions ( const char *  newval,
void *  extra 
)

Definition at line 2250 of file elog.c.

2251{
2252 backtrace_function_list = (char *) extra;
2253}
static char * backtrace_function_list
Definition: elog.c:117

References backtrace_function_list.

◆ assign_log_destination()

void assign_log_destination ( const char *  newval,
void *  extra 
)

Definition at line 2323 of file elog.c.

2324{
2325 Log_destination = *((int *) extra);
2326}
int Log_destination
Definition: elog.c:111

References Log_destination.

◆ assign_syslog_facility()

void assign_syslog_facility ( int  newval,
void *  extra 
)

Definition at line 2364 of file elog.c.

2365{
2366#ifdef HAVE_SYSLOG
2367 /*
2368 * As above, don't thrash the syslog connection unnecessarily.
2369 */
2370 if (syslog_facility != newval)
2371 {
2372 if (openlog_done)
2373 {
2374 closelog();
2375 openlog_done = false;
2376 }
2378 }
2379#endif
2380 /* Without syslog support, just ignore it */
2381}
#define newval
static int syslog_facility
Definition: guc_tables.c:591

References newval, and syslog_facility.

◆ assign_syslog_ident()

void assign_syslog_ident ( const char *  newval,
void *  extra 
)

Definition at line 2332 of file elog.c.

2333{
2334#ifdef HAVE_SYSLOG
2335 /*
2336 * guc.c is likely to call us repeatedly with same parameters, so don't
2337 * thrash the syslog connection unnecessarily. Also, we do not re-open
2338 * the connection until needed, since this routine will get called whether
2339 * or not Log_destination actually mentions syslog.
2340 *
2341 * Note that we make our own copy of the ident string rather than relying
2342 * on guc.c's. This may be overly paranoid, but it ensures that we cannot
2343 * accidentally free a string that syslog is still using.
2344 */
2345 if (syslog_ident == NULL || strcmp(syslog_ident, newval) != 0)
2346 {
2347 if (openlog_done)
2348 {
2349 closelog();
2350 openlog_done = false;
2351 }
2352 free(syslog_ident);
2353 syslog_ident = strdup(newval);
2354 /* if the strdup fails, we will cope in write_syslog() */
2355 }
2356#endif
2357 /* Without syslog support, just ignore it */
2358}
#define free(a)
Definition: header.h:65

References free, and newval.

◆ check_backtrace_functions()

bool check_backtrace_functions ( char **  newval,
void **  extra,
GucSource  source 
)

Definition at line 2189 of file elog.c.

2190{
2191 int newvallen = strlen(*newval);
2192 char *someval;
2193 int validlen;
2194 int i;
2195 int j;
2196
2197 /*
2198 * Allow characters that can be C identifiers and commas as separators, as
2199 * well as some whitespace for readability.
2200 */
2201 validlen = strspn(*newval,
2202 "0123456789_"
2203 "abcdefghijklmnopqrstuvwxyz"
2204 "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
2205 ", \n\t");
2206 if (validlen != newvallen)
2207 {
2208 GUC_check_errdetail("Invalid character.");
2209 return false;
2210 }
2211
2212 if (*newval[0] == '\0')
2213 {
2214 *extra = NULL;
2215 return true;
2216 }
2217
2218 /*
2219 * Allocate space for the output and create the copy. We could discount
2220 * whitespace chars to save some memory, but it doesn't seem worth the
2221 * trouble.
2222 */
2223 someval = guc_malloc(LOG, newvallen + 1 + 1);
2224 if (!someval)
2225 return false;
2226 for (i = 0, j = 0; i < newvallen; i++)
2227 {
2228 if ((*newval)[i] == ',')
2229 someval[j++] = '\0'; /* next item */
2230 else if ((*newval)[i] == ' ' ||
2231 (*newval)[i] == '\n' ||
2232 (*newval)[i] == '\t')
2233 ; /* ignore these */
2234 else
2235 someval[j++] = (*newval)[i]; /* copy anything else */
2236 }
2237
2238 /* two \0s end the setting */
2239 someval[j] = '\0';
2240 someval[j + 1] = '\0';
2241
2242 *extra = someval;
2243 return true;
2244}
#define LOG
Definition: elog.h:31
void * guc_malloc(int elevel, size_t size)
Definition: guc.c:638
#define GUC_check_errdetail
Definition: guc.h:481
int j
Definition: isn.c:78
int i
Definition: isn.c:77

References GUC_check_errdetail, guc_malloc(), i, j, LOG, and newval.

◆ check_log_destination()

bool check_log_destination ( char **  newval,
void **  extra,
GucSource  source 
)

Definition at line 2259 of file elog.c.

2260{
2261 char *rawstring;
2262 List *elemlist;
2263 ListCell *l;
2264 int newlogdest = 0;
2265 int *myextra;
2266
2267 /* Need a modifiable copy of string */
2268 rawstring = pstrdup(*newval);
2269
2270 /* Parse string into list of identifiers */
2271 if (!SplitIdentifierString(rawstring, ',', &elemlist))
2272 {
2273 /* syntax error in list */
2274 GUC_check_errdetail("List syntax is invalid.");
2275 pfree(rawstring);
2276 list_free(elemlist);
2277 return false;
2278 }
2279
2280 foreach(l, elemlist)
2281 {
2282 char *tok = (char *) lfirst(l);
2283
2284 if (pg_strcasecmp(tok, "stderr") == 0)
2285 newlogdest |= LOG_DESTINATION_STDERR;
2286 else if (pg_strcasecmp(tok, "csvlog") == 0)
2287 newlogdest |= LOG_DESTINATION_CSVLOG;
2288 else if (pg_strcasecmp(tok, "jsonlog") == 0)
2289 newlogdest |= LOG_DESTINATION_JSONLOG;
2290#ifdef HAVE_SYSLOG
2291 else if (pg_strcasecmp(tok, "syslog") == 0)
2292 newlogdest |= LOG_DESTINATION_SYSLOG;
2293#endif
2294#ifdef WIN32
2295 else if (pg_strcasecmp(tok, "eventlog") == 0)
2296 newlogdest |= LOG_DESTINATION_EVENTLOG;
2297#endif
2298 else
2299 {
2300 GUC_check_errdetail("Unrecognized key word: \"%s\".", tok);
2301 pfree(rawstring);
2302 list_free(elemlist);
2303 return false;
2304 }
2305 }
2306
2307 pfree(rawstring);
2308 list_free(elemlist);
2309
2310 myextra = (int *) guc_malloc(LOG, sizeof(int));
2311 if (!myextra)
2312 return false;
2313 *myextra = newlogdest;
2314 *extra = myextra;
2315
2316 return true;
2317}
#define LOG_DESTINATION_JSONLOG
Definition: elog.h:489
#define LOG_DESTINATION_SYSLOG
Definition: elog.h:486
#define LOG_DESTINATION_STDERR
Definition: elog.h:485
#define LOG_DESTINATION_EVENTLOG
Definition: elog.h:487
#define LOG_DESTINATION_CSVLOG
Definition: elog.h:488
void list_free(List *list)
Definition: list.c:1546
void pfree(void *pointer)
Definition: mcxt.c:1524
#define lfirst(lc)
Definition: pg_list.h:172
int pg_strcasecmp(const char *s1, const char *s2)
Definition: pgstrcasecmp.c:36
Definition: pg_list.h:54
bool SplitIdentifierString(char *rawstring, char separator, List **namelist)
Definition: varlena.c:3525

References GUC_check_errdetail, guc_malloc(), lfirst, list_free(), LOG, LOG_DESTINATION_CSVLOG, LOG_DESTINATION_EVENTLOG, LOG_DESTINATION_JSONLOG, LOG_DESTINATION_STDERR, LOG_DESTINATION_SYSLOG, newval, pfree(), pg_strcasecmp(), pstrdup(), and SplitIdentifierString().

◆ check_log_of_query()

bool check_log_of_query ( ErrorData edata)

Definition at line 2757 of file elog.c.

2758{
2759 /* log required? */
2761 return false;
2762
2763 /* query log wanted? */
2764 if (edata->hide_stmt)
2765 return false;
2766
2767 /* query string available? */
2768 if (debug_query_string == NULL)
2769 return false;
2770
2771 return true;
2772}
static bool is_log_level_output(int elevel, int log_min_level)
Definition: elog.c:202
int log_min_error_statement
Definition: guc_tables.c:526
const char * debug_query_string
Definition: postgres.c:88
int elevel
Definition: elog.h:421
bool hide_stmt
Definition: elog.h:424

References debug_query_string, ErrorData::elevel, ErrorData::hide_stmt, is_log_level_output(), and log_min_error_statement.

Referenced by send_message_to_server_log(), write_csvlog(), and write_jsonlog().

◆ CopyErrorData()

ErrorData * CopyErrorData ( void  )

Definition at line 1768 of file elog.c.

1769{
1771 ErrorData *newedata;
1772
1773 /*
1774 * we don't increment recursion_depth because out-of-memory here does not
1775 * indicate a problem within the error subsystem.
1776 */
1778
1780
1781 /* Copy the struct itself */
1782 newedata = (ErrorData *) palloc(sizeof(ErrorData));
1783 memcpy(newedata, edata, sizeof(ErrorData));
1784
1785 /*
1786 * Make copies of separately-allocated strings. Note that we copy even
1787 * theoretically-constant strings such as filename. This is because those
1788 * could point into JIT-created code segments that might get unloaded at
1789 * transaction cleanup. In some cases we need the copied ErrorData to
1790 * survive transaction boundaries, so we'd better copy those strings too.
1791 */
1792 if (newedata->filename)
1793 newedata->filename = pstrdup(newedata->filename);
1794 if (newedata->funcname)
1795 newedata->funcname = pstrdup(newedata->funcname);
1796 if (newedata->domain)
1797 newedata->domain = pstrdup(newedata->domain);
1798 if (newedata->context_domain)
1799 newedata->context_domain = pstrdup(newedata->context_domain);
1800 if (newedata->message)
1801 newedata->message = pstrdup(newedata->message);
1802 if (newedata->detail)
1803 newedata->detail = pstrdup(newedata->detail);
1804 if (newedata->detail_log)
1805 newedata->detail_log = pstrdup(newedata->detail_log);
1806 if (newedata->hint)
1807 newedata->hint = pstrdup(newedata->hint);
1808 if (newedata->context)
1809 newedata->context = pstrdup(newedata->context);
1810 if (newedata->backtrace)
1811 newedata->backtrace = pstrdup(newedata->backtrace);
1812 if (newedata->message_id)
1813 newedata->message_id = pstrdup(newedata->message_id);
1814 if (newedata->schema_name)
1815 newedata->schema_name = pstrdup(newedata->schema_name);
1816 if (newedata->table_name)
1817 newedata->table_name = pstrdup(newedata->table_name);
1818 if (newedata->column_name)
1819 newedata->column_name = pstrdup(newedata->column_name);
1820 if (newedata->datatype_name)
1821 newedata->datatype_name = pstrdup(newedata->datatype_name);
1822 if (newedata->constraint_name)
1823 newedata->constraint_name = pstrdup(newedata->constraint_name);
1824 if (newedata->internalquery)
1825 newedata->internalquery = pstrdup(newedata->internalquery);
1826
1827 /* Use the calling context for string allocation */
1829
1830 return newedata;
1831}
#define CHECK_STACK_DEPTH()
Definition: elog.c:165
static ErrorData errordata[ERRORDATA_STACK_SIZE]
Definition: elog.c:146
Assert(PointerIsAligned(start, uint64))
void * palloc(Size size)
Definition: mcxt.c:1317
MemoryContext CurrentMemoryContext
Definition: mcxt.c:143
MemoryContext ErrorContext
Definition: mcxt.c:150
char * schema_name
Definition: elog.h:439
char * context
Definition: elog.h:436
const char * domain
Definition: elog.h:429
char * internalquery
Definition: elog.h:446
struct MemoryContextData * assoc_context
Definition: elog.h:450
const char * filename
Definition: elog.h:426
char * datatype_name
Definition: elog.h:442
char * detail
Definition: elog.h:433
const char * context_domain
Definition: elog.h:430
const char * funcname
Definition: elog.h:428
char * table_name
Definition: elog.h:440
char * backtrace
Definition: elog.h:437
char * message
Definition: elog.h:432
char * detail_log
Definition: elog.h:434
const char * message_id
Definition: elog.h:438
char * hint
Definition: elog.h:435
char * constraint_name
Definition: elog.h:443
char * column_name
Definition: elog.h:441

References Assert(), ErrorData::assoc_context, ErrorData::backtrace, CHECK_STACK_DEPTH, ErrorData::column_name, ErrorData::constraint_name, ErrorData::context, ErrorData::context_domain, CurrentMemoryContext, ErrorData::datatype_name, ErrorData::detail, ErrorData::detail_log, ErrorData::domain, ErrorContext, errordata, errordata_stack_depth, ErrorData::filename, ErrorData::funcname, ErrorData::hint, ErrorData::internalquery, ErrorData::message, ErrorData::message_id, palloc(), pstrdup(), ErrorData::schema_name, and ErrorData::table_name.

Referenced by _SPI_commit(), _SPI_rollback(), exec_stmt_block(), GetConnection(), initTrie(), plperl_return_next(), plperl_spi_commit(), plperl_spi_exec(), plperl_spi_exec_prepared(), plperl_spi_fetchrow(), plperl_spi_prepare(), plperl_spi_query(), plperl_spi_query_prepared(), plperl_spi_rollback(), plperl_util_elog(), pltcl_commit(), pltcl_elog(), pltcl_rollback(), pltcl_subtrans_abort(), PLy_commit(), PLy_output(), PLy_rollback(), PLy_spi_subtransaction_abort(), and ReorderBufferProcessTXN().

◆ DebugFileOpen()

void DebugFileOpen ( void  )

Definition at line 2133 of file elog.c.

2134{
2135 int fd,
2136 istty;
2137
2138 if (OutputFileName[0])
2139 {
2140 /*
2141 * A debug-output file name was given.
2142 *
2143 * Make sure we can write the file, and find out if it's a tty.
2144 */
2145 if ((fd = open(OutputFileName, O_CREAT | O_APPEND | O_WRONLY,
2146 0666)) < 0)
2147 ereport(FATAL,
2149 errmsg("could not open file \"%s\": %m", OutputFileName)));
2150 istty = isatty(fd);
2151 close(fd);
2152
2153 /*
2154 * Redirect our stderr to the debug output file.
2155 */
2156 if (!freopen(OutputFileName, "a", stderr))
2157 ereport(FATAL,
2159 errmsg("could not reopen file \"%s\" as stderr: %m",
2160 OutputFileName)));
2161
2162 /*
2163 * If the file is a tty and we're running under the postmaster, try to
2164 * send stdout there as well (if it isn't a tty then stderr will block
2165 * out stdout, so we may as well let stdout go wherever it was going
2166 * before).
2167 */
2168 if (istty && IsUnderPostmaster)
2169 if (!freopen(OutputFileName, "a", stdout))
2170 ereport(FATAL,
2172 errmsg("could not reopen file \"%s\" as stdout: %m",
2173 OutputFileName)));
2174 }
2175}
int errcode_for_file_access(void)
Definition: elog.c:877
int errmsg(const char *fmt,...)
Definition: elog.c:1071
#define FATAL
Definition: elog.h:41
#define ereport(elevel,...)
Definition: elog.h:149
bool IsUnderPostmaster
Definition: globals.c:120
char OutputFileName[MAXPGPATH]
Definition: globals.c:79
#define close(a)
Definition: win32.h:12
static int fd(const char *x, int i)
Definition: preproc-init.c:105

References close, ereport, errcode_for_file_access(), errmsg(), FATAL, fd(), IsUnderPostmaster, OutputFileName, and generate_unaccent_rules::stdout.

Referenced by BaseInit().

◆ EmitErrorReport()

void EmitErrorReport ( void  )

Definition at line 1709 of file elog.c.

1710{
1712 MemoryContext oldcontext;
1713
1716 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1717
1718 /*
1719 * Reset the formatted timestamp fields before emitting any logs. This
1720 * includes all the log destinations and emit_log_hook, as the latter
1721 * could use log_line_prefix or the formatted timestamps.
1722 */
1723 saved_timeval_set = false;
1724 formatted_log_time[0] = '\0';
1725
1726 /*
1727 * Call hook before sending message to log. The hook function is allowed
1728 * to turn off edata->output_to_server, so we must recheck that afterward.
1729 * Making any other change in the content of edata is not considered
1730 * supported.
1731 *
1732 * Note: the reason why the hook can only turn off output_to_server, and
1733 * not turn it on, is that it'd be unreliable: we will never get here at
1734 * all if errstart() deems the message uninteresting. A hook that could
1735 * make decisions in that direction would have to hook into errstart(),
1736 * where it would have much less information available. emit_log_hook is
1737 * intended for custom log filtering and custom log message transmission
1738 * mechanisms.
1739 *
1740 * The log hook has access to both the translated and original English
1741 * error message text, which is passed through to allow it to be used as a
1742 * message identifier. Note that the original text is not available for
1743 * detail, detail_log, hint and context text elements.
1744 */
1745 if (edata->output_to_server && emit_log_hook)
1746 (*emit_log_hook) (edata);
1747
1748 /* Send to server log, if enabled */
1749 if (edata->output_to_server)
1751
1752 /* Send to client, if enabled */
1753 if (edata->output_to_client)
1755
1756 MemoryContextSwitchTo(oldcontext);
1758}
static char formatted_log_time[FORMATTED_TS_LEN]
Definition: elog.c:161
static void send_message_to_frontend(ErrorData *edata)
Definition: elog.c:3550
static bool saved_timeval_set
Definition: elog.c:157
static int recursion_depth
Definition: elog.c:150
emit_log_hook_type emit_log_hook
Definition: elog.c:106
static void send_message_to_server_log(ErrorData *edata)
Definition: elog.c:3247
static MemoryContext MemoryContextSwitchTo(MemoryContext context)
Definition: palloc.h:124
bool output_to_server
Definition: elog.h:422
bool output_to_client
Definition: elog.h:423

References ErrorData::assoc_context, CHECK_STACK_DEPTH, emit_log_hook, errordata, errordata_stack_depth, formatted_log_time, MemoryContextSwitchTo(), ErrorData::output_to_client, ErrorData::output_to_server, recursion_depth, saved_timeval_set, send_message_to_frontend(), and send_message_to_server_log().

Referenced by AutoVacLauncherMain(), AutoVacWorkerMain(), BackgroundWorkerMain(), BackgroundWriterMain(), CheckpointerMain(), DisableSubscriptionAndExit(), do_autovacuum(), errfinish(), IoWorkerMain(), perform_work_item(), pgarch_archiveXlog(), PostgresMain(), ReplSlotSyncWorkerMain(), WalSummarizerMain(), and WalWriterMain().

◆ err_generic_string()

int err_generic_string ( int  field,
const char *  str 
)

Definition at line 1534 of file elog.c.

1535{
1537
1538 /* we don't bother incrementing recursion_depth */
1540
1541 switch (field)
1542 {
1545 break;
1546 case PG_DIAG_TABLE_NAME:
1548 break;
1551 break;
1554 break;
1557 break;
1558 default:
1559 elog(ERROR, "unsupported ErrorData field id: %d", field);
1560 break;
1561 }
1562
1563 return 0; /* return value does not matter */
1564}
static void set_errdata_field(MemoryContextData *cxt, char **ptr, const char *str)
Definition: elog.c:1570
#define elog(elevel,...)
Definition: elog.h:226
#define PG_DIAG_SCHEMA_NAME
Definition: postgres_ext.h:60
#define PG_DIAG_CONSTRAINT_NAME
Definition: postgres_ext.h:64
#define PG_DIAG_DATATYPE_NAME
Definition: postgres_ext.h:63
#define PG_DIAG_TABLE_NAME
Definition: postgres_ext.h:61
#define PG_DIAG_COLUMN_NAME
Definition: postgres_ext.h:62

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::column_name, ErrorData::constraint_name, ErrorData::datatype_name, elog, ERROR, errordata, errordata_stack_depth, PG_DIAG_COLUMN_NAME, PG_DIAG_CONSTRAINT_NAME, PG_DIAG_DATATYPE_NAME, PG_DIAG_SCHEMA_NAME, PG_DIAG_TABLE_NAME, ErrorData::schema_name, set_errdata_field(), str, and ErrorData::table_name.

Referenced by errdatatype(), errdomainconstraint(), errtable(), errtablecolname(), errtableconstraint(), exec_stmt_raise(), PLy_elog_impl(), and PLy_output().

◆ err_gettext()

static const char * err_gettext ( const char *  str)
inlinestatic

Definition at line 306 of file elog.c.

307{
308#ifdef ENABLE_NLS
310 return str;
311 else
312 return gettext(str);
313#else
314 return str;
315#endif
316}
#define gettext(x)
Definition: c.h:1150

References gettext, in_error_recursion_trouble(), and str.

◆ err_sendstring()

static void err_sendstring ( StringInfo  buf,
const char *  str 
)
static

Definition at line 3538 of file elog.c.

3539{
3542 else
3544}
void pq_sendstring(StringInfo buf, const char *str)
Definition: pqformat.c:195
void pq_send_ascii_string(StringInfo buf, const char *str)
Definition: pqformat.c:227

References buf, in_error_recursion_trouble(), pq_send_ascii_string(), pq_sendstring(), and str.

Referenced by send_message_to_frontend().

◆ errbacktrace()

int errbacktrace ( void  )

Definition at line 1093 of file elog.c.

1094{
1096 MemoryContext oldcontext;
1097
1100 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1101
1102 set_backtrace(edata, 1);
1103
1104 MemoryContextSwitchTo(oldcontext);
1106
1107 return 0;
1108}
static pg_noinline void set_backtrace(ErrorData *edata, int num_skip)
Definition: elog.c:1117

References ErrorData::assoc_context, CHECK_STACK_DEPTH, errordata, errordata_stack_depth, MemoryContextSwitchTo(), recursion_depth, and set_backtrace().

◆ errcode()

int errcode ( int  sqlerrcode)

Definition at line 854 of file elog.c.

855{
857
858 /* we don't bother incrementing recursion_depth */
860
861 edata->sqlerrcode = sqlerrcode;
862
863 return 0; /* return value does not matter */
864}
int sqlerrcode
Definition: elog.h:431

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::sqlerrcode.

Referenced by _arrq_cons(), _bt_binsrch_insert(), _bt_check_third_page(), _bt_check_unique(), _bt_checkpage(), _bt_get_endpoint(), _bt_getmeta(), _bt_gettrueroot(), _bt_insert_parent(), _bt_insertonpg(), _bt_lock_subtree_parent(), _bt_mark_page_halfdead(), _bt_pagedel(), _bt_preprocess_array_keys_final(), _bt_split(), _bt_unlink_halfdead_page(), _crypt_blowfish_rn(), _crypt_gensalt_sha(), _hash_addovflpage(), _hash_checkpage(), _hash_doinsert(), _hash_first(), _hash_init(), _hash_ovflblkno_to_bitno(), _intbig_in(), _intbig_out(), _lca(), _lt_q_regex(), _ltree_compress(), _PG_init(), _SPI_commit(), _SPI_execute_plan(), _SPI_rollback(), _tarWriteHeader(), AbortBufferIO(), accumArrayResult(), accumArrayResultArr(), aclcheck_error(), aclcheck_error_col(), aclinsert(), aclitemin(), aclparse(), aclremove(), add_guc_variable(), add_json(), add_jsonb(), add_parameter_name(), add_reloption_kind(), add_size(), addCompoundAffixFlagValue(), AddEnumLabel(), addFamilyMember(), addFkConstraint(), addFkRecurseReferencing(), AddQual(), addRangeTableEntryForCTE(), addRangeTableEntryForFunction(), addRangeTableEntryForJoin(), addRangeTableEntryForSubquery(), addRangeTableEntryForTableFunc(), addRangeTableEntryForValues(), AddRelationNewConstraints(), AddRelationNotNullConstraints(), AddRoleMems(), addTargetToSortList(), addUnicode(), addUnicodeChar(), AdjustIntervalForTypmod(), AdjustNotNullInheritance(), AdjustTimestampForTypmod(), advance_windowaggregate(), afterTriggerMarkEvents(), AfterTriggerSetState(), AggregateCreate(), alen_object_start(), alen_scalar(), AllocateDir(), AllocateFile(), AllocateVfd(), AllocSetContextCreateInternal(), AlterDatabase(), AlterDatabaseOwner(), AlterDatabaseRefreshColl(), AlterDomainDropConstraint(), AlterDomainValidateConstraint(), AlterEventTrigger(), AlterEventTriggerOwner(), AlterEventTriggerOwner_internal(), AlterEventTriggerOwner_oid(), AlterExtensionNamespace(), AlterForeignDataWrapper(), AlterForeignDataWrapperOwner(), AlterForeignDataWrapperOwner_internal(), AlterForeignDataWrapperOwner_oid(), AlterForeignServer(), AlterForeignServerOwner(), AlterForeignServerOwner_oid(), AlterFunction(), AlterObjectNamespace_internal(), AlterObjectRename_internal(), AlterOperator(), AlterOpFamily(), AlterOpFamilyAdd(), AlterOpFamilyDrop(), AlterPolicy(), AlterPublication(), AlterPublicationOptions(), AlterPublicationOwner(), AlterPublicationOwner_internal(), AlterPublicationOwner_oid(), AlterPublicationSchemas(), AlterRelationNamespaceInternal(), AlterReplicationSlot(), AlterRole(), AlterRoleSet(), AlterSchemaOwner(), AlterStatistics(), AlterSubscription(), AlterSubscription_refresh(), AlterSubscriptionOwner(), AlterSubscriptionOwner_internal(), AlterSubscriptionOwner_oid(), AlterSystemSetConfigFile(), AlterTableMoveAll(), AlterTableNamespace(), AlterTableSpaceOptions(), AlterTSConfiguration(), AlterType(), AlterTypeNamespace(), AlterTypeNamespace_oid(), AlterTypeNamespaceInternal(), AlterTypeOwner(), AlterTypeOwnerInternal(), AlterUserMapping(), amcheck_index_mainfork_expected(), amcheck_lock_relation_and_check(), analyzeCTE(), analyzeCTETargetList(), anybit_typmodin(), anychar_typmodin(), anytime_typmod_check(), anytime_typmodin(), anytimestamp_typmod_check(), anytimestamp_typmodin(), appendElement(), appendKey(), apply_dispatch(), apply_handle_begin_prepare(), apply_handle_commit(), apply_handle_origin(), apply_handle_prepare(), apply_handle_stream_abort(), apply_handle_stream_commit(), apply_handle_stream_prepare(), apply_handle_stream_start(), apply_handle_stream_stop(), apply_typmod(), apply_typmod_special(), ApplyRetrieveRule(), apw_start_database_worker(), apw_start_leader_worker(), array_agg_array_combine(), array_agg_array_transfn(), array_agg_deserialize(), array_agg_transfn(), array_append(), array_cat(), array_cmp(), array_contain_compare(), array_eq(), array_exec_setup(), array_fill(), array_fill_internal(), array_fill_with_lower_bounds(), array_get_slice(), array_in(), array_iterator(), array_map(), array_position_common(), array_positions(), array_prepend(), array_recv(), array_replace_internal(), array_sample(), array_send(), array_set_element(), array_set_element_expanded(), array_set_slice(), array_sort_internal(), array_subscript_check_subscripts(), array_subscript_transform(), array_to_datum_internal(), array_to_tsvector(), ArrayCheckBoundsSafe(), ArrayGetIntegerTypmods(), ArrayGetNItemsSafe(), arrq_cons(), ascii(), ASN1_STRING_to_text(), assign_collations_walker(), assign_hypothetical_collations(), assign_record_type_identifier(), assignable_custom_variable_name(), assignOperTypes(), assignProcTypes(), AssignTransactionId(), AssignTypeArrayOid(), AssignTypeMultirangeArrayOid(), AssignTypeMultirangeOid(), Async_Notify(), ATAddCheckNNConstraint(), ATAddForeignKeyConstraint(), AtEOSubXact_SPI(), AtEOXact_SPI(), ATExecAddColumn(), ATExecAddConstraint(), ATExecAddIdentity(), ATExecAddIndexConstraint(), ATExecAddInherit(), ATExecAddOf(), ATExecAlterColumnGenericOptions(), ATExecAlterColumnType(), ATExecAlterConstraint(), ATExecAttachPartition(), ATExecAttachPartitionIdx(), ATExecChangeOwner(), ATExecClusterOn(), ATExecColumnDefault(), ATExecDetachPartition(), ATExecDropColumn(), ATExecDropConstraint(), ATExecDropExpression(), ATExecDropIdentity(), ATExecDropInherit(), ATExecDropNotNull(), ATExecDropOf(), ATExecGenericOptions(), ATExecReplicaIdentity(), ATExecSetCompression(), ATExecSetExpression(), ATExecSetIdentity(), ATExecSetNotNull(), ATExecSetOptions(), ATExecSetRelOptions(), ATExecSetStatistics(), ATExecSetStorage(), ATExecValidateConstraint(), ATPrepAddColumn(), ATPrepAddInherit(), ATPrepAddPrimaryKey(), ATPrepAlterColumnType(), AtPrepare_Locks(), AtPrepare_Notify(), AtPrepare_RelationMap(), ATPrepChangePersistence(), ATPrepCmd(), ATPrepDropColumn(), ATPrepDropExpression(), ATPrepSetTableSpace(), ATRewriteTable(), ATRewriteTables(), ATSimplePermissions(), AtSubCommit_childXids(), attach_internal(), AttachPartitionEnsureIndexes(), attribute_statistics_update(), auth_failed(), auth_peer(), autoinc(), autoprewarm_database_main(), autoprewarm_start_worker(), BackendInitialize(), BackendStartup(), BackgroundWorkerInitializeConnection(), BackgroundWorkerInitializeConnectionByOid(), BackgroundWorkerStateChange(), BaseBackupGetTargetHandle(), BasicOpenFilePerm(), bbsink_gzip_new(), bbsink_lz4_new(), bbsink_server_archive_contents(), bbsink_server_manifest_contents(), bbsink_server_new(), bbsink_zstd_new(), be_lo_close(), be_lo_get_fragment(), be_lo_lseek(), be_lo_lseek64(), be_lo_tell(), be_lo_tell64(), be_lo_unlink(), be_tls_init(), be_tls_open_server(), be_tls_read(), be_tls_write(), before_shmem_exit(), begin_prepare_cb_wrapper(), BeginCopyFrom(), BeginCopyTo(), BeginTransactionBlock(), bernoulli_beginsamplescan(), bgworker_die(), binary_decode(), binary_encode(), bit(), bit_and(), bit_catenate(), bit_in(), bit_or(), bit_overlay(), bit_recv(), bitgetbit(), bitsetbit(), bitsubstring(), bittoint4(), bittoint8(), bitxor(), bloom_get_procinfo(), blvalidate(), boolin(), BootstrapModeMain(), bpchar(), bpchar_input(), bqarr_in(), bqarr_out(), brin_bloom_summary_in(), brin_bloom_summary_recv(), brin_desummarize_range(), brin_doinsert(), brin_doupdate(), brin_getinsertbuffer(), brin_metapage_info(), brin_minmax_multi_summary_in(), brin_minmax_multi_summary_recv(), brin_page_items(), brin_page_type(), brin_revmap_data(), brin_summarize_range(), brinGetTupleForHeapBlock(), brininsert(), brinRevmapDesummarizeRange(), brinvalidate(), bt_check_every_level(), bt_check_level_from_leftmost(), bt_child_check(), bt_child_highkey_check(), bt_downlink_missing_check(), bt_entry_unique_check(), bt_index_block_validate(), bt_index_check_callback(), bt_leftmost_ignoring_half_dead(), bt_metap(), bt_multi_page_stats(), bt_normalize_tuple(), bt_page_items_bytea(), bt_page_items_internal(), bt_page_stats_internal(), bt_recheck_sibling_links(), bt_report_duplicate(), bt_right_page_check_scankey(), bt_target_page_check(), bt_tuple_present_callback(), BTreeTupleGetHeapTIDCareful(), btvacuumpage(), btvalidate(), buffer_readv_report(), build_attrmap_by_name(), build_attrmap_by_position(), build_column_default(), build_datatype(), build_server_first_message(), build_tuplestore_recursively(), BuildDescForRelation(), buildRelationAliases(), BuildRelationExtStatistics(), builtin_locale_encoding(), builtin_validate_locale(), BumpContextCreate(), bytea_int2(), bytea_int4(), bytea_int8(), bytea_overlay(), bytea_substring(), byteaGetBit(), byteaGetByte(), byteain(), byteaout(), byteaSetBit(), byteaSetByte(), calc_rank_cd(), calculate_frame_offsets(), call_bool_check_hook(), call_enum_check_hook(), call_int_check_hook(), call_pltcl_start_proc(), call_real_check_hook(), call_string_check_hook(), cannotCastJsonbValue(), cash_dist(), cash_div_cash(), cash_div_float8(), cash_div_int64(), cash_in(), cash_mi_cash(), cash_mul_float8(), cash_mul_int64(), cash_pl_cash(), CastCreate(), cfunc_resolve_polymorphic_argtypes(), changeDependenciesOn(), char2wchar(), check_acl(), check_agg_arguments(), check_agg_arguments_walker(), check_agglevels_and_constraints(), check_and_init_gencol(), check_and_set_sync_info(), check_av_worker_gucs(), check_can_set_role(), check_circularity(), check_collation_set(), check_conn_params(), check_default_partition_contents(), check_default_table_access_method(), check_default_tablespace(), check_default_text_search_config(), check_duplicates_in_publist(), check_enable_rls(), check_encoding_locale_matches(), check_escape_warning(), check_exclusion_or_unique_constraint(), check_for_column_name_collision(), check_foreign_key(), check_ident_usermap(), check_index_is_clusterable(), check_index_page(), check_lateral_ref_ok(), check_locale(), check_nested_generated_walker(), check_new_partition_bound(), check_oauth_validator(), check_object_ownership(), check_of_type(), check_parameter_resolution_walker(), check_password(), check_primary_key(), check_publication_add_relation(), check_publication_add_schema(), check_publications(), check_publications_origin(), check_relation_block_range(), check_relation_privileges(), check_relation_relkind(), check_relation_updatable(), check_restricted_library_name(), check_role(), check_role_grantor(), check_role_membership_authorization(), check_rolespec_name(), check_safe_enum_use(), check_session_authorization(), check_simple_rowfilter_expr_walker(), check_sql_fn_statement(), check_sql_stmt_retval(), check_srf_call_placement(), check_ssl_key_file_permissions(), check_stack_depth(), check_string_escape_warning(), check_temp_tablespaces(), check_transform_function(), check_unicode_value(), check_valid_extension_name(), check_valid_version_name(), CheckAlterPublication(), CheckAlterSubOption(), CheckAlterTableIsSafe(), CheckAndGetDbnameFromConninfo(), CheckAttributeNamesTypes(), CheckAttributeType(), CheckCmdReplicaIdentity(), checkDataDir(), checkDomainOwner(), CheckDuplicateColumnOrPathNames(), checkEnumOwner(), checkExprIsVarFree(), CheckForSerializableConflictIn(), CheckForSerializableConflictOut(), CheckForSerializableConflictOutNeeded(), CheckForSessionAndXactLocks(), CheckFunctionValidatorAccess(), CheckIndexCompatible(), checkInsertTargets(), checkJsonOutputFormat(), CheckLogicalDecodingRequirements(), checkMembershipInCurrentExtension(), CheckMyDatabase(), checkNameSpaceConflicts(), CheckPredicate(), CheckPubRelationColumnList(), CheckRecoveryConflictDeadlock(), CheckRelationTableSpaceMove(), CheckRequiredParameterValues(), CheckRestrictedOperation(), checkRuleResultList(), CheckSASLAuth(), CheckSelectLocking(), CheckSetNamespace(), checkSharedDependencies(), CheckSlotPermissions(), CheckSlotRequirements(), checkStringLen(), CheckSubscriptionRelkind(), CheckTableNotInUse(), CheckTablespaceDirectory(), checkTargetlistEntrySQL92(), checkTimezoneIsUsedForCast(), CheckTransactionBlock(), CheckValidResultRel(), CheckValidRowMarkRel(), CheckVarSlotCompatibility(), checkViewColumns(), checkWellFormedRecursion(), checkWellFormedRecursionWalker(), chr(), cidr_abbrev(), cidr_set_masklen(), circle_in(), circle_poly(), circle_recv(), ClientAuthentication(), CloneFkReferencing(), ClosePipeFromProgram(), ClosePipeToProgram(), cluster(), cluster_rel(), coerce_record_to_complex(), coerce_to_boolean(), coerce_to_common_type(), coerce_to_specific_type_typmod(), coerceJsonFuncExpr(), CollationCreate(), collectMatchBitmap(), colNameToVar(), CommandCounterIncrement(), CommentObject(), commit_prepared_cb_wrapper(), comparetup_index_btree_tiebreak(), compatConnectbyTupleDescs(), compatCrosstabTupleDescs(), compatible_oper(), compile_plperl_function(), compile_pltcl_function(), compileTheLexeme(), compileTheSubstitute(), complex_in(), compute_common_attribute(), compute_function_attributes(), compute_return_type(), ComputeIndexAttrs(), ComputePartitionAttrs(), connect_pg_server(), connectby_text(), connectby_text_serial(), ConstraintSetParentConstraint(), construct_md_array(), ConversionCreate(), convert_and_check_filename(), convert_any_priv_string(), convert_column_name(), convert_function_name(), convert_type_name(), convertJsonbArray(), convertJsonbObject(), cookConstraint(), cookDefault(), copy_replication_slot(), copy_table(), CopyFrom(), CopyFromBinaryOneRow(), CopyFromTextLikeOneRow(), CopyGetAttnums(), CopyGetData(), CopyReadAttributesCSV(), CopyReadAttributesText(), CopyReadBinaryAttribute(), CopyReadLineText(), CopyXLogRecordToWAL(), countVariablesFromJsonb(), create_ctas_nodata(), create_distinct_paths(), create_ordinary_grouping_paths(), create_pg_locale_icu(), create_tablespace_directories(), CreateAccessMethod(), CreateCast(), CreateConversionCommand(), createdb(), CreateDecodingContext(), CreateEventTrigger(), CreateExtension(), CreateExtensionInternal(), CreateForeignDataWrapper(), CreateForeignServer(), CreateFunction(), CreateInheritance(), CreateInitDecodingContext(), CreateLockFile(), createNewConnection(), CreateOpFamily(), CreatePolicy(), CreatePortal(), CreatePredicateLock(), CreateProceduralLanguage(), CreatePublication(), CreateRole(), CreateSchemaCommand(), CreateStatistics(), CreateSubscription(), CreateTableAsRelExists(), CreateTableSpace(), CreateTransform(), CreateTriggerFiringOn(), CreateUserMapping(), crosstab(), crosstab_hash(), cube_a_f8(), cube_a_f8_f8(), cube_c_f8(), cube_c_f8_f8(), cube_coord(), cube_coord_llur(), cube_recv(), cube_subset(), cube_yyerror(), currtid_for_view(), currtid_internal(), currval_oid(), cursor_to_xml(), cursor_to_xmlschema(), dacos(), dacosd(), dacosh(), dasin(), dasind(), datanh(), date2timestamp_opt_overflow(), date2timestamptz_opt_overflow(), date_in(), date_mi(), date_mii(), date_pli(), date_recv(), daterange_canonical(), datetime_timestamp(), DateTimeParseError(), datetimetz_timestamptz(), datum_to_json_internal(), datum_to_jsonb_internal(), datumGetSize(), db_encoding_convert(), dblink_build_sql_delete(), dblink_build_sql_insert(), dblink_build_sql_update(), dblink_conn_not_avail(), dblink_connect(), dblink_connstr_check(), dblink_exec(), dblink_fdw_validator(), dblink_fetch(), dblink_get_conn(), dblink_res_error(), dblink_security_check(), DCH_from_char(), DCH_to_char(), dcos(), dcosd(), dcot(), dcotd(), DeadLockReport(), DecodeTimezoneName(), deconstruct_array(), DeconstructQualifiedName(), defGetBoolean(), defGetCopyHeaderChoice(), defGetCopyLogVerbosityChoice(), defGetCopyOnErrorChoice(), defGetCopyRejectLimitOption(), defGetGeneratedColsOption(), defGetInt32(), defGetInt64(), defGetNumeric(), defGetObjectId(), defGetQualifiedName(), defGetStreamingMode(), defGetString(), defGetStringList(), defGetTypeLength(), defGetTypeName(), define_custom_variable(), DefineAggregate(), DefineCollation(), DefineCompositeType(), DefineDomain(), DefineEnum(), DefineIndex(), DefineOpClass(), DefineOperator(), DefineOpFamily(), DefineQueryRewrite(), DefineRange(), DefineRelation(), DefineSavepoint(), DefineSequence(), DefineTSConfiguration(), DefineTSDictionary(), DefineTSParser(), DefineTSTemplate(), DefineType(), DefineView(), DefineVirtualRelation(), deleteConnection(), DeleteInheritsTuple(), deserialize_deflist(), destroy_tablespace_directories(), DetermineTimeZoneAbbrevOffsetTS(), dintdict_init(), dispell_init(), div_var(), div_var_int(), dlog1(), dlog10(), do_analyze_rel(), do_pg_backup_start(), do_pg_backup_stop(), do_setval(), do_to_timestamp(), DoCopy(), domain_check_input(), domain_state_setup(), domainAddCheckConstraint(), domainAddNotNullConstraint(), DoPortalRewind(), dpow(), DropConfigurationMapping(), dropconstraint_internal(), DropDatabase(), dropdb(), DropErrorMsgNonExistent(), DropErrorMsgWrongType(), dropOperators(), DropOwnedObjects(), dropProcedures(), DropRole(), DropSubscription(), DropTableSpace(), dsa_allocate_extended(), dsa_attach(), dshash_create(), dsimple_init(), dsin(), dsind(), dsm_backend_startup(), dsm_create(), dsnowball_init(), dsqrt(), dsynonym_init(), dtan(), dtand(), dtoi2(), dtoi4(), dtoi8(), dummy_object_relabel(), dumptuples(), dxsyn_init(), EA_get_flat_size(), each_array_start(), each_scalar(), each_worker_jsonb(), ean2isn(), ean2string(), elements_object_start(), elements_scalar(), elements_worker_jsonb(), emit_audit_message(), EnableDisableRule(), EnableDisableTrigger(), EnableLockPagesPrivilege(), encrypt_password(), EndPrepare(), EndTransactionBlock(), enforce_generic_type_consistency(), enlargeStringInfo(), entry_reset(), enum_cmp_internal(), enum_first(), enum_in(), enum_last(), enum_out(), enum_range_all(), enum_range_bounds(), enum_recv(), enum_send(), EnumValuesCreate(), errcode_apply_conflict(), errcode_for_dynamic_shared_memory(), errno_from_string(), error_commit_ts_disabled(), error_duplicate_filter_variable(), error_multiple_recovery_targets(), error_view_not_updatable(), errorConflictingDefElem(), errorMissingColumn(), errorMissingRTE(), esc_dec_len(), esc_decode(), EvalPlanQualFetchRowMark(), EvaluateParams(), exec_assign_value(), exec_bind_message(), exec_check_assignable(), exec_describe_portal_message(), exec_describe_statement_message(), exec_dynquery_with_params(), exec_eval_datum(), exec_eval_expr(), exec_execute_message(), exec_init_tuple_store(), exec_move_row_from_fields(), exec_object_restorecon(), exec_parse_message(), exec_replication_command(), exec_run_select(), exec_simple_query(), exec_stmt_assert(), exec_stmt_case(), exec_stmt_close(), exec_stmt_dynexecute(), exec_stmt_execsql(), exec_stmt_fetch(), exec_stmt_forc(), exec_stmt_foreach_a(), exec_stmt_fori(), exec_stmt_getdiag(), exec_stmt_open(), exec_stmt_raise(), exec_stmt_return(), exec_stmt_return_next(), exec_stmt_return_query(), ExecAlterDefaultPrivilegesStmt(), ExecAlterExtensionContentsRecurse(), ExecAlterExtensionContentsStmt(), ExecAlterExtensionStmt(), ExecBRInsertTriggers(), ExecBSDeleteTriggers(), ExecBSInsertTriggers(), ExecBSTruncateTriggers(), ExecBSUpdateTriggers(), ExecBuildUpdateProjection(), ExecCallTriggerFunc(), ExecCheckIndexConstraints(), ExecCheckPlanOutput(), ExecCheckTupleVisible(), ExecConstraints(), ExecCrossPartitionUpdate(), ExecCrossPartitionUpdateForeignKey(), execCurrentOf(), ExecCustomMarkPos(), ExecCustomRestrPos(), ExecDelete(), ExecEvalArrayExpr(), ExecEvalConstraintCheck(), ExecEvalConstraintNotNull(), ExecEvalCurrentOfExpr(), ExecEvalFieldSelect(), ExecEvalJsonCoercionFinish(), ExecEvalJsonExprPath(), ExecEvalParamExtern(), ExecEvalWholeRowVar(), ExecFindPartition(), ExecGrant_Language_check(), ExecGrant_Relation(), ExecGrant_Type_check(), ExecInitAgg(), ExecInitExprRec(), ExecInitFunc(), ExecInitMergeJoin(), ExecInitSubscriptingRef(), ExecLockRows(), ExecMakeFunctionResultSet(), ExecMakeTableFunctionResult(), ExecMergeMatched(), ExecOnConflictUpdate(), ExecOpenScanRelation(), ExecPartitionCheckEmitError(), ExecPrepareTuplestoreResult(), ExecReindex(), ExecScanSubPlan(), ExecSecLabelStmt(), ExecSetParamPlan(), ExecSetVariableStmt(), ExecUpdate(), execute_extension_script(), execute_sql_string(), executeBinaryArithmExpr(), ExecuteCallStmt(), executeDateTimeMethod(), ExecuteDoStmt(), ExecuteGrantStmt(), executeItemOptUnwrapTarget(), executeKeyValueMethod(), executeNumericItemMethod(), ExecuteQuery(), ExecuteTruncate(), executeUnaryArithmExpr(), ExecVacuum(), ExecWithCheckOptions(), ExecWithoutOverlapsNotEmpty(), ExitPostmaster(), exp_var(), expand_col_privileges(), expand_vacuum_rel(), ExpandAllTables(), ExpandColumnRefStar(), expandTableLikeClause(), ExportSnapshot(), exprType(), ExtendBufferedRelLocal(), ExtendBufferedRelShared(), extract_date(), extract_variadic_args(), ExtractExtensionList(), extractModify(), FastPathGetRelationLockEntry(), fatal_llvm_error_handler(), fatal_llvm_new_handler(), fatal_system_new_handler(), fetch_array_arg_replace_nulls(), fetch_cursor_param_value(), fetch_finfo_record(), fetch_fp_info(), fetch_remote_table_info(), fetch_table_list(), FetchPreparedStatement(), file_fdw_validator(), fileIterateForeignScan(), FileWriteV(), finalize_grouping_exprs_walker(), find_composite_type_dependencies(), find_expr_references_walker(), find_in_path(), find_my_exec(), find_option(), find_provider(), find_typed_table_dependencies(), findDependentObjects(), FindFKPeriodOpers(), findRangeCanonicalFunction(), findRangeSubOpclass(), findRangeSubtypeDiffFunction(), findTargetlistEntrySQL92(), findTypeAnalyzeFunction(), findTypeInputFunction(), findTypeOutputFunction(), findTypeReceiveFunction(), findTypeSendFunction(), findTypeSubscriptingFunction(), findTypeTypmodinFunction(), findTypeTypmodoutFunction(), finish_nodeitem(), finite_interval_mi(), finite_interval_pl(), fireRIRrules(), fixed_paramref_hook(), flatten_set_variable_args(), flattenJsonPathParseItem(), float4in_internal(), float8_timestamptz(), float8in_internal(), float_overflow_error(), float_underflow_error(), float_zero_divide_error(), FloatExceptionHandler(), fmgr_info_cxt_security(), fmgr_internal_validator(), fmgr_sql(), fmgr_sql_validator(), forbidden_in_wal_sender(), forkname_to_number(), free_parsestate(), FreezeMultiXactId(), from_char_parse_int_len(), from_char_seq_search(), from_char_set_int(), from_char_set_mode(), fsm_page_contents(), ftoi2(), ftoi4(), ftoi8(), func_select_candidate(), g_cube_distance(), g_int_compress(), g_int_decompress(), gai_strerror(), gbtreekey_in(), gbtreekey_out(), gen_random_uuid(), generate_error_response(), generate_nonunion_paths(), generate_recursion_path(), generate_series_step_int4(), generate_series_step_int8(), generate_series_step_numeric(), generate_series_timestamp(), generate_series_timestamptz_internal(), generate_uuidv7(), generateClonedIndexStmt(), generateSerialExtraStmts(), GenerationContextCreate(), Generic_Text_IC_like(), GenericMatchText(), get_am_type_oid(), get_attr_stat_type(), get_cached_rowtype(), get_cast_oid(), get_collation_actual_version_builtin(), get_collation_oid(), get_connect_string(), get_controlfile_by_exact_path(), get_conversion_oid(), get_crosstab_tuplestore(), get_database_oid(), get_domain_constraint_oid(), get_event_trigger_oid(), get_expr_result_tupdesc(), get_extension_oid(), get_fn_opclass_options(), get_foreign_data_wrapper_oid(), get_foreign_server_oid(), get_func_expr(), get_language_oid(), get_multirange_io_data(), get_namespace_oid(), get_object_address(), get_object_address_attrdef(), get_object_address_attribute(), get_object_address_defacl(), get_object_address_opf_member(), get_object_address_publication_rel(), get_object_address_publication_schema(), get_object_address_relobject(), get_object_address_type(), get_object_address_usermapping(), get_page_from_raw(), get_publication_oid(), get_range_io_data(), get_raw_page_1_9(), get_raw_page_fork_1_9(), get_raw_page_internal(), get_record_type_from_argument(), get_record_type_from_query(), get_relation_by_qualified_name(), get_relation_constraint_attnos(), get_relation_constraint_oid(), get_relation_info(), get_relation_policy_oid(), get_required_extension(), get_rewrite_oid(), get_role_oid(), get_rolespec_oid(), get_rolespec_tuple(), get_rte_attribute_is_dropped(), get_sort_group_operators(), get_sql_insert(), get_sql_update(), get_statistics_object_oid(), get_subscription_oid(), get_tablespace_oid(), get_th(), get_transform_oid(), get_trigger_oid(), get_ts_config_oid(), get_ts_dict_oid(), get_ts_parser_func(), get_ts_parser_oid(), get_ts_template_func(), get_ts_template_oid(), get_tsearch_config_filename(), get_tuple_of_interest(), get_windowfunc_expr_helper(), getAffixFlagSet(), getArrayIndex(), GetAttributeCompression(), GetAttributeStorage(), GetColumnDefCollation(), GetConfFilesInDir(), GetConfigOption(), GetConfigOptionByName(), GetConfigOptionResetString(), GetConflictingVirtualXIDs(), GetCurrentCommandId(), GetCurrentTimeUsec(), getdatafield(), GetDefaultOpClass(), GetDefaultTablespace(), GetExtensibleNodeEntry(), GetFdwRoutine(), GetFdwRoutineByServerId(), GetFileBackupMethod(), getid(), GetIndexAmRoutineByAmId(), getJsonPathVariable(), GetLocalVictimBuffer(), GetMultiXactIdMembers(), GetNewMultiXactId(), GetNewTransactionId(), getNextFlagFromString(), GetOldestUnsummarizedLSN(), GetOperatorFromCompareType(), GetRunningTransactionData(), GetSafeSnapshot(), GetSerializableTransactionSnapshot(), GetSerializableTransactionSnapshotInt(), GetSnapshotData(), gettoken_query(), gettoken_query_standard(), gettoken_tsvector(), getTokenTypes(), GetTupleForTrigger(), getTypeBinaryInputInfo(), getTypeBinaryOutputInfo(), getTypeInputInfo(), getTypeOutputInfo(), GetUserMapping(), GetUserNameFromId(), GetWALBlockInfo(), getWeights(), ghstore_in(), ghstore_out(), gin_check_parent_keys_consistency(), gin_check_posting_tree_parent_keys_consistency(), gin_clean_pending_list(), gin_leafpage_items(), gin_metapage_info(), gin_page_opaque_info(), ginadjustmembers(), GinBufferInit(), ginCombineData(), GinFormTuple(), ginvalidate(), gist_page_items(), gist_page_items_bytea(), gist_page_opaque_info(), gistadjustmembers(), gistcheckpage(), gistSplit(), gistUserPicksplit(), gistvalidate(), GrantRole(), grouping_planner(), gtrgm_in(), gtrgm_out(), gtsvectorin(), guc_malloc(), guc_realloc(), handle_streamed_transaction(), HandleConcurrentAbort(), HandleFunctionRequest(), HandleUploadManifestPacket(), has_sequence_privilege_id(), has_sequence_privilege_id_id(), has_sequence_privilege_id_name(), has_sequence_privilege_name(), has_sequence_privilege_name_id(), has_sequence_privilege_name_name(), hash_array(), hash_array_extended(), hash_array_start(), hash_bitmap_info(), hash_create(), hash_metapage_info(), hash_multirange(), hash_multirange_extended(), hash_page_items(), hash_page_stats(), hash_page_type(), hash_range(), hash_range_extended(), hash_record(), hash_record_extended(), hash_scalar(), hash_search_with_hash_value(), hashbpchar(), hashbpcharextended(), hashtext(), hashtextextended(), hashvalidate(), heap_acquire_tuplock(), heap_create(), heap_create_with_catalog(), heap_delete(), heap_fetch_toast_slice(), heap_force_common(), heap_form_minimal_tuple(), heap_form_tuple(), heap_getnext(), heap_inplace_lock(), heap_lock_tuple(), heap_page_items(), heap_pre_freeze_checks(), heap_prepare_freeze_tuple(), heap_prepare_insert(), heap_truncate_check_FKs(), heap_tuple_infomask_flags(), heap_update(), heapam_index_build_range_scan(), heapam_index_validate_scan(), heapam_tuple_lock(), hex_decode_safe(), hlparsetext(), HoldPinnedPortals(), hstore_from_array(), hstore_from_arrays(), hstore_populate_record(), hstore_recv(), hstore_subscript_assign(), hstore_subscript_transform(), hstore_to_plpython(), hstoreArrayToPairs(), hstoreCheckKeyLen(), hstoreCheckKeyLength(), hstoreCheckValLen(), hstoreCheckValLength(), i4tochar(), i4toi2(), i8tooid(), icu_language_tag(), icu_validate_locale(), identify_update_path(), ImportForeignSchema(), ImportSnapshot(), in_range_float4_float8(), in_range_float8_float8(), in_range_int2_int4(), in_range_int4_int4(), in_range_int4_int8(), in_range_int8_int8(), in_range_interval_interval(), in_range_numeric_numeric(), in_range_time_interval(), in_range_timestamp_interval(), in_range_timestamptz_interval(), in_range_timetz_interval(), inclusion_get_procinfo(), index_check_primary_key(), index_checkable(), index_concurrently_create_copy(), index_constraint_create(), index_create(), index_delete_check_htid(), index_drop(), index_form_tuple_context(), index_opclass_options(), IndexOnlyNext(), inet_abbrev(), inet_merge(), inet_set_masklen(), inetand(), inetmi(), inetor(), infer_arbiter_indexes(), init_execution_state(), init_MultiFuncCall(), init_params(), init_sexpr(), initArrayResultArr(), InitControlFile(), InitFileAccess(), initGinState(), initialize_dh(), initialize_ecdh(), initialize_peragg(), InitializeClientEncoding(), InitializeMaxBackends(), InitializeSessionUserId(), InitLocalBuffers(), InitMaterializedSRF(), InitPgFdwOptions(), InitPostgres(), InitProcess(), InitTempTableNamespace(), initTrie(), InitWalRecovery(), InitXLogReaderState(), inner_subltree(), insert_username(), InsertRule(), instantiate_empty_record_variable(), int24div(), int24mi(), int24mul(), int24pl(), int28div(), int28mi(), int28mul(), int28pl(), int2_dist(), int2abs(), int2div(), int2mi(), int2mod(), int2mul(), int2pl(), int2um(), int2vectorin(), int2vectorrecv(), int42div(), int42mi(), int42mul(), int42pl(), int48div(), int48mi(), int48mul(), int48pl(), int4_dist(), int4abs(), int4div(), int4gcd_internal(), int4inc(), int4lcm(), int4mi(), int4mod(), int4mul(), int4pl(), int4random(), int4range_canonical(), int4um(), int82(), int82div(), int82mi(), int82mul(), int82pl(), int84(), int84div(), int84mi(), int84mul(), int84pl(), int8_dist(), int8abs(), int8dec(), int8div(), int8gcd_internal(), int8inc(), int8lcm(), int8mi(), int8mod(), int8mul(), int8pl(), int8random(), int8range_canonical(), int8um(), internal_get_result_type(), internal_inetpl(), internal_load_library(), interpret_AS_clause(), interpret_func_parallel(), interpret_func_support(), interpret_function_parameter_list(), interval_avg(), interval_div(), interval_in(), interval_justify_days(), interval_justify_hours(), interval_justify_interval(), interval_mi(), interval_mul(), interval_part_common(), interval_pl(), interval_sum(), interval_time(), interval_trunc(), interval_um_internal(), intervaltypmodin(), intorel_startup(), inv_open(), inv_read(), inv_seek(), inv_truncate(), inv_write(), iso8859_to_utf8(), issue_xlog_fsync(), IsThereCollationInNamespace(), IsThereFunctionInNamespace(), IsThereOpClassInNamespace(), IsThereOpFamilyInNamespace(), json_agg_transfn_worker(), json_build_object_worker(), json_errsave_error(), json_object(), json_object_agg_transfn_worker(), json_object_two_arg(), json_validate(), jsonb_agg_transfn_worker(), jsonb_array_length(), jsonb_build_object_worker(), jsonb_delete(), jsonb_delete_array(), jsonb_delete_idx(), jsonb_delete_path(), jsonb_insert(), jsonb_object(), jsonb_object_agg_transfn_worker(), jsonb_object_keys(), jsonb_object_two_arg(), jsonb_path_match_internal(), jsonb_set(), jsonb_set_lax(), jsonb_subscript_check_subscripts(), jsonb_subscript_transform(), JsonEncodeDateTime(), JsonItemFromDatum(), jsonpath_yyerror(), jsonPathFromCstring(), JsonPathQuery(), JsonPathValue(), JsValueToJsObject(), LargeObjectDrop(), lastval(), length_in_encoding(), libpqrcv_alter_slot(), libpqrcv_check_conninfo(), libpqrcv_connect(), libpqrcv_create_slot(), libpqrcv_endstreaming(), libpqrcv_exec(), libpqrcv_get_conninfo(), libpqrcv_get_dbname_from_conninfo(), libpqrcv_identify_system(), libpqrcv_processTuples(), libpqrcv_readtimelinehistoryfile(), libpqrcv_receive(), libpqrcv_send(), libpqrcv_startstreaming(), libpqsrv_connect_prepare(), like_fixed_prefix(), line_construct_pp(), line_decode(), line_in(), line_recv(), ln_var(), lo_get_fragment_internal(), lo_read(), lo_truncate_internal(), lo_write(), load_categories_hash(), load_critical_index(), load_dh_file(), load_enum_cache_data(), load_external_function(), load_hba(), load_libraries(), LoadArchiveLibrary(), LoadPublications(), LocalToUtf(), locate_stem_module(), lock_twophase_recover(), LockAcquireExtended(), LockGXact(), LockSchemaList(), LockTableRecurse(), LockViewRecurse_walker(), LogicalParallelApplyLoop(), logicalrep_rel_mark_updatable(), logicalrep_rel_open(), logicalrep_report_missing_or_gen_attrs(), logicalrep_worker_attach(), logicalrep_worker_launch(), LogicalRepApplyLoop(), LogicalRepSyncTableStart(), lookup_agg_function(), lookup_am_handler_func(), lookup_fdw_handler_func(), lookup_rowtype_tupdesc_domain(), lookup_rowtype_tupdesc_internal(), lookup_type_cache(), LookupFuncName(), LookupFuncWithArgs(), LookupOperName(), LookupTypeNameExtended(), LookupTypeNameOid(), lpad(), lt_q_regex(), ltree_concat(), ltree_gist_in(), ltree_gist_out(), ltree_gist_relopts_validator(), ltree_to_plpython(), ltxtq_out(), ltxtq_send(), lz4_decompress_datum(), lz4_decompress_datum_slice(), macaddr8_in(), macaddr8tomacaddr(), macaddr_in(), make_absolute_path(), make_callstmt_target(), make_date(), make_distinct_op(), make_expanded_record_from_tupdesc(), make_expanded_record_from_typeid(), make_inh_translation_list(), make_interval(), make_libc_collator(), make_modifytable(), make_op(), make_outerjoininfo(), make_pathkeys_for_window(), make_result_opt_error(), make_row_comparison_op(), make_row_distinct_op(), make_ruledef(), make_scalar_array_op(), make_time(), make_timestamp_internal(), make_timestamptz_at_timezone(), make_tsvector(), makeMultirangeTypeName(), makepol(), makeRangeVarFromNameList(), makeWholeRowVar(), map_sql_value_to_xml_value(), mark_index_clustered(), MarkAsPreparing(), MarkGUCPrefixReserved(), MarkInheritDetached(), MarkPortalActive(), matchLocks(), MatchText(), materializeResult(), md5_bytea(), md5_text(), md_readv_report(), mdextend(), mdreadv(), mdzeroextend(), MemoryContextAllocationFailure(), merge_acl_with_grant(), merge_collation_state(), merge_publications(), MergeAttributes(), MergeAttributesIntoExisting(), MergeCheckConstraint(), MergeChildAttribute(), MergeConstraintsIntoExisting(), MergeInheritedAttribute(), MergeWithExistingConstraint(), metaphone(), minmax_multi_get_procinfo(), moddatetime(), movedb(), mul_size(), multirange_constructor2(), multirange_in(), namerecv(), NamespaceCreate(), network_host(), network_in(), network_out(), network_recv(), network_show(), NextCopyFromRawFieldsInternal(), nextval_internal(), NIAddAffix(), NIImportAffixes(), NIImportDictionary(), NIImportOOAffixes(), NISortDictionary(), NonFiniteIntervalPart(), NonFiniteTimestampTzPart(), normal_rand(), NUM_processor(), NUMDesc_prepare(), numeric_div_opt_error(), numeric_div_trunc(), numeric_fac(), numeric_in(), numeric_int2(), numeric_int4_opt_error(), numeric_int8_opt_error(), numeric_ln(), numeric_log(), numeric_mod_opt_error(), numeric_pg_lsn(), numeric_power(), numeric_recv(), numeric_sqrt(), numerictypmodin(), numericvar_to_double_no_overflow(), oauth_exchange(), oauth_init(), ObjectsInPublicationToOids(), oidvectorrecv(), okeys_array_start(), okeys_scalar(), on_proc_exit(), on_shmem_exit(), OnConflict_CheckForSerializationFailure(), op_error(), OpClassCacheLookup(), OpenPipeStream(), OpenTableList(), OpenTransientFilePerm(), OperatorCreate(), OperatorShellMake(), OperatorUpd(), OperatorValidateParams(), OpFamilyCacheLookup(), pa_send_data(), pa_wait_for_xact_finish(), page_checksum_internal(), page_header(), PageAddItemExtended(), PageGetItemIdCareful(), PageIndexMultiDelete(), PageIndexTupleDelete(), PageIndexTupleDeleteNoCompact(), PageIndexTupleOverwrite(), PageIsVerified(), PageRepairFragmentation(), pair_decode(), palloc_btree_page(), ParallelApplyWorkerMain(), ParallelWorkerMain(), ParameterAclLookup(), parse_affentry(), parse_and_validate_value(), parse_basebackup_options(), parse_datetime(), parse_extension_control_file(), parse_fcall_arguments(), parse_format(), parse_hba_auth_opt(), parse_hba_line(), parse_ident(), parse_jsonb_index_flags(), parse_key_value_arrays(), parse_kvpairs_for_auth(), parse_lquery(), parse_ltree(), parse_one_reloption(), parse_output_parameters(), parse_phrase_operator(), parse_publication_options(), parse_re_flags(), parse_sane_timezone(), parse_snapshot(), parse_subscription_options(), parse_test_flags(), parse_tsquery(), parseCheckAggregates(), ParseConfigFile(), ParseConfigFp(), parseCreateReplSlotOptions(), ParseExplainOptionList(), ParseFuncOrColumn(), parseIntFromText(), parseNameAndArgTypes(), parseRelOptionsInternal(), parserOpenTable(), parsetext(), parseTypeString(), parseUnicode(), parseVxidFromText(), parseXidFromText(), partitioned_table_reloptions(), path_add(), path_decode(), path_in(), path_poly(), path_recv(), PathNameOpenFilePerm(), pclose_check(), percentile_cont_final_common(), percentile_disc_final(), perform_base_backup(), perform_default_encoding_conversion(), PerformCursorOpen(), PerformPortalClose(), PerformPortalFetch(), PerformWalRecovery(), pg_analyze_and_rewrite_varparams(), pg_any_to_server(), pg_attribute_aclcheck_all_ext(), pg_attribute_aclmask_ext(), pg_backup_start(), pg_backup_stop(), pg_base64_decode(), pg_be_scram_build_secret(), pg_buffercache_evict(), pg_cancel_backend(), pg_class_aclmask_ext(), pg_clear_attribute_stats(), pg_collation_actual_version(), pg_collation_for(), pg_convert(), pg_create_restore_point(), pg_crypt(), pg_cryptohash_create(), pg_current_logfile(), pg_current_wal_flush_lsn(), pg_current_wal_insert_lsn(), pg_current_wal_lsn(), pg_database_collation_actual_version(), pg_database_size_oid(), pg_decode_startup(), pg_decrypt(), pg_decrypt_iv(), pg_dependencies_in(), pg_dependencies_recv(), pg_do_encoding_conversion(), pg_encrypt(), pg_encrypt_iv(), pg_event_trigger_ddl_commands(), pg_event_trigger_dropped_objects(), pg_event_trigger_table_rewrite_oid(), pg_event_trigger_table_rewrite_reason(), pg_extension_config_dump(), pg_freespace(), pg_gen_salt(), pg_gen_salt_rounds(), pg_get_expr_worker(), pg_get_functiondef(), pg_get_multixact_members(), pg_get_object_address(), pg_get_serial_sequence(), pg_get_wal_record_info(), pg_get_wal_records_info_till_end_of_wal(), pg_get_wal_replay_pause_state(), pg_get_wal_stats_till_end_of_wal(), pg_hmac_create(), pg_import_system_collations(), pg_is_wal_replay_paused(), pg_largeobject_aclmask_snapshot(), pg_log_standby_snapshot(), pg_logical_slot_get_changes_guts(), pg_ls_replslotdir(), pg_ls_tmpdir(), pg_lsn_in(), pg_lsn_mii(), pg_lsn_pli(), pg_mcv_list_in(), pg_mcv_list_recv(), pg_namespace_aclmask_ext(), pg_ndistinct_in(), pg_ndistinct_recv(), pg_nextoid(), pg_parameter_acl_aclmask(), pg_prewarm(), pg_promote(), pg_random_bytes(), pg_read_binary_file_common(), pg_read_file_common(), pg_regerror(), pg_relpages(), pg_relpages_impl(), pg_relpagesbyid(), pg_replication_origin_create(), pg_replication_origin_session_progress(), pg_replication_origin_xact_setup(), pg_replication_slot_advance(), pg_sequence_parameters(), pg_set_regex_collation(), pg_size_bytes(), pg_snapshot_recv(), pg_split_walfile_name(), pg_stat_get_progress_info(), pg_stat_reset_shared(), pg_stat_reset_subscription_stats(), pg_stat_statements_info(), pg_stat_statements_internal(), pg_stats_ext_mcvlist_items(), pg_stop_making_pinned_objects(), pg_strtoint16_safe(), pg_strtoint32_safe(), pg_strtoint64_safe(), pg_switch_wal(), pg_sync_replication_slots(), pg_tablespace_location(), pg_tablespace_size_oid(), pg_terminate_backend(), pg_to_ascii(), pg_type_aclmask_ext(), pg_unicode_to_server(), pg_visibility(), pg_visibility_map(), pg_wait_until_termination(), pg_wal_replay_pause(), pg_wal_replay_resume(), pg_wal_summary_contents(), pg_walfile_name(), pg_walfile_name_offset(), pgfdw_cancel_query_begin(), pgfdw_cancel_query_end(), pgfdw_reject_incomplete_xact_state_change(), pgfdw_report_error(), pgfdw_security_check(), pgfdw_xact_callback(), PGLC_localeconv(), pglz_decompress_datum(), pglz_decompress_datum_slice(), pgoutput_column_list_init(), pgoutput_startup(), pgrowlocks(), PGSharedMemoryCreate(), pgss_shmem_startup(), pgstat_get_kind_from_str(), pgstat_heap(), pgstat_init_function_usage(), pgstat_relation(), pgstat_reset_replslot(), pgstatginindex(), pgstatginindex_internal(), pgstathashindex(), pgstatindex(), pgstatindex_impl(), pgstatindexbyid(), pgstattuple(), pgstattuple_approx(), pgstattuple_approx_internal(), pgstattuplebyid(), pipe_read_line(), placeChar(), plan_recursive_revoke(), plperl_array_to_datum(), plperl_build_tuple_result(), plperl_call_perl_event_trigger_func(), plperl_call_perl_func(), plperl_call_perl_trigger_func(), plperl_create_sub(), plperl_func_handler(), plperl_init_interp(), plperl_modify_tuple(), plperl_return_next_internal(), plperl_spi_execute_fetch_result(), plperl_sv_to_datum(), plperl_sv_to_literal(), plperl_to_hstore(), plperl_trigger_handler(), plperl_trusted_init(), plperl_untrusted_init(), plperl_validator(), plpgsql_build_datatype_arrayof(), plpgsql_build_variable(), plpgsql_compile_callback(), plpgsql_exec_event_trigger(), plpgsql_exec_function(), plpgsql_exec_get_datum_type(), plpgsql_exec_get_datum_type_info(), plpgsql_exec_trigger(), plpgsql_param_eval_generic(), plpgsql_param_eval_generic_ro(), plpgsql_param_eval_recfield(), plpgsql_parse_cwordrowtype(), plpgsql_parse_cwordtype(), plpgsql_parse_err_condition(), plpgsql_parse_wordrowtype(), plpgsql_parse_wordtype(), plpgsql_post_column_ref(), plpgsql_recognize_err_condition(), plpgsql_validator(), plpgsql_yyerror(), plpython_to_hstore(), pltcl_build_tuple_result(), pltcl_elog(), pltcl_func_handler(), pltcl_trigger_handler(), PLy_cursor_fetch(), PLy_elog_impl(), PLy_exec_function(), PLy_exec_trigger(), PLy_modify_tuple(), PLy_output(), PLy_procedure_create(), PLy_spi_execute_fetch_result(), PLyGenericObject_ToComposite(), PLyMapping_ToComposite(), PLyNumber_ToJsonbValue(), PLyObject_AsString(), PLyObject_ToJsonbValue(), PLySequence_ToArray(), PLySequence_ToArray_recurse(), PLySequence_ToComposite(), PLyUnicode_ToComposite(), policy_role_list_to_array(), poly_in(), poly_recv(), populate_array_check_dimension(), populate_array_report_expected_array(), populate_joinrel_with_paths(), populate_recordset_array_element_start(), populate_recordset_object_start(), populate_recordset_scalar(), populate_recordset_worker(), PortalDrop(), PortalRunSelect(), PortalSetResultFormat(), postgres_fdw_validator(), postgresAcquireSampleRowsFunc(), postgresBeginForeignInsert(), postgresExecForeignTruncate(), postgresImportForeignSchema(), PostgresMain(), postgresql_fdw_validator(), PostgresSingleUserMain(), PostmasterMain(), PostPrepare_Locks(), power_var(), power_var_int(), pq_copymsgbytes(), pq_getmessage(), pq_getmsgbyte(), pq_getmsgbytes(), pq_getmsgend(), pq_getmsgrawstring(), pq_getmsgstring(), pq_getmsgtext(), pq_startmsgread(), PreCommit_CheckForSerializationFailure(), PreCommit_Notify(), PreCommit_Portals(), predicatelock_twophase_recover(), PrefetchBuffer(), prepare_cb_wrapper(), prepare_sql_fn_parse_info(), PrepareForIncrementalBackup(), PrepareQuery(), PrepareRedoAdd(), PrepareTransaction(), preprocess_grouping_sets(), prepTuplestoreResult(), PreventCommandDuringRecovery(), PreventCommandIfParallelMode(), PreventCommandIfReadOnly(), PreventInTransactionBlock(), printtup_prepare_info(), ProcArrayAdd(), ProcedureCreate(), process_function_rte_ref(), process_matched_tle(), process_owned_by(), process_postgres_switches(), ProcessCancelRequestPacket(), ProcessConfigFileInternal(), ProcessCopyOptions(), ProcessInterrupts(), ProcessParallelApplyMessage(), ProcessParallelApplyMessages(), ProcessParallelMessages(), ProcessPgArchInterrupts(), ProcessRecoveryConflictInterrupt(), ProcessRepliesIfAny(), ProcessSSLStartup(), ProcessStandbyMessage(), ProcessStartupPacket(), ProcessTwoPhaseBuffer(), processTypesSpec(), ProcessUtilitySlow(), protect_out_of_mem(), prsd_headline(), prseof(), prssyntaxerror(), pub_collist_validate(), publication_add_relation(), publication_add_schema(), PublicationDropSchemas(), PublicationDropTables(), pushquery(), PushTransaction(), pushval_asis(), pushValue(), pushValue_internal(), pvsnprintf(), px_crypt_des(), px_crypt_shacrypt(), px_THROW_ERROR(), qtext_load_file(), QTN2QT(), QualifiedNameGetCreationNamespace(), query_to_xml_internal(), queryin(), QueueCheckConstraintValidation(), QueueNNConstraintValidation(), quickdie(), random_numeric(), random_var(), range_constructor3(), range_minus_internal(), range_parse(), range_parse_bound(), range_parse_flags(), range_serialize(), range_union_internal(), RangeVarAdjustRelationPersistence(), RangeVarCallbackForAlterRelation(), RangeVarCallbackForAttachIndex(), RangeVarCallbackForDropRelation(), RangeVarCallbackForLockTable(), RangeVarCallbackForPolicy(), RangeVarCallbackForReindexIndex(), RangeVarCallbackForRenameRule(), RangeVarCallbackForRenameTrigger(), RangeVarCallbackMaintainsTable(), RangeVarCallbackOwnsRelation(), RangeVarGetAndCheckCreationNamespace(), RangeVarGetCreationNamespace(), RangeVarGetRelidExtended(), raw_heap_insert(), RE_compile(), RE_compile_and_cache(), RE_wchar_execute(), read_any_attr(), read_attr_value(), read_backup_label(), read_binary_file(), read_client_final_message(), read_client_first_message(), read_dictionary(), read_objtype_from_string(), read_relmap_file(), read_tablespace_map(), read_whole_file(), ReadArrayBinary(), ReadArrayDimensions(), ReadArrayStr(), ReadArrayToken(), ReadBufferExtended(), ReadControlFile(), ReadDimensionInt(), readRecoverySignalFile(), ReadReplicationSlot(), readstoplist(), ReadTwoPhaseFile(), ReassignOwnedObjects(), ReceiveCopyBinaryHeader(), recompute_limits(), record_cmp(), record_eq(), record_image_cmp(), record_image_eq(), record_in(), record_recv(), recordDependencyOnCurrentExtension(), RecoveryRequiresIntParameter(), recursive_revoke(), recv_password_packet(), refresh_by_match_merge(), RefreshMatViewByOid(), refuseDupeIndexAttach(), regclassin(), regcollationin(), regcomp_auth_token(), regconfigin(), regdictionaryin(), regex_fixed_prefix(), regexp_count(), regexp_fixed_prefix(), regexp_instr(), regexp_like(), regexp_match(), regexp_split_to_array(), regexp_split_to_table(), regexp_substr(), RegisterBackgroundWorker(), RegisterExtensibleNodeEntry(), RegisterTimeout(), regnamespacein(), regoperatorin(), regoperin(), regprocedurein(), regprocin(), REGRESS_exec_check_perms(), REGRESS_object_access_hook(), REGRESS_object_access_hook_str(), REGRESS_utility_command(), regrolein(), reindex_index(), reindex_relation(), ReindexMultipleTables(), ReindexRelationConcurrently(), reject_target_detail(), relation_statistics_update(), RelationBuildPartitionKey(), RelationCacheInitializePhase3(), RelationCopyStorage(), RelationGetBufferForTuple(), RelationSetNewRelfilenumber(), ReleaseOneSerializableXact(), ReleaseSavepoint(), RememberAllDependentForRebuilding(), remove_tablespace_symlink(), RemoveExtensionById(), RemoveInheritance(), RemoveObjects(), RemovePolicyById(), RemoveRelations(), RemoveRewriteRuleById(), RemoveSubscriptionRel(), RemoveTriggerById(), RemoveUserMapping(), rename_constraint_internal(), rename_policy(), renameatt_check(), renameatt_internal(), RenameConstraintById(), RenameDatabase(), RenameEnumLabel(), RenameRelationInternal(), RenameRewriteRule(), RenameRole(), RenameSchema(), RenameTableSpace(), renametrig(), renametrig_internal(), RenameType(), RenameTypeInternal(), repeat(), replace_percent_placeholders(), replace_rte_variables_mutator(), replace_text_regexp(), ReplaceVarFromTargetList(), replication_yyerror(), ReplicationSlotAcquire(), ReplicationSlotAlter(), ReplicationSlotCreate(), ReplicationSlotDrop(), ReplicationSlotDropAtPubNode(), ReplicationSlotsDropDBSlots(), ReplicationSlotValidateName(), replorigin_advance(), replorigin_by_name(), replorigin_by_oid(), replorigin_check_prerequisites(), replorigin_create(), replorigin_session_reset(), replorigin_session_setup(), replorigin_state_clear(), ReplSlotSyncWorkerMain(), report_invalid_encoding(), report_name_conflict(), report_namespace_conflict(), report_newlocale_failure(), report_untranslatable_char(), reportDependentObjects(), ReportNotNullViolationError(), ReportSlotConnectionError(), ReportWalSummaryError(), reserveAllocatedDesc(), resolve_anyarray_from_others(), resolve_anyelement_from_others(), resolve_anymultirange_from_others(), resolve_anyrange_from_others(), resolve_column_ref(), resolve_unique_index_expr(), ResolveOpClass(), RestoreGUCState(), RestoreSlotFromDisk(), restrict_and_check_grant(), revalidate_rectypeid(), RevalidateCachedQuery(), revmap_physical_extend(), RewriteQuery(), rewriteRuleAction(), rewriteSearchAndCycle(), rewriteTargetListIU(), rewriteTargetView(), ri_CheckTrigger(), ri_FetchConstraintInfo(), RI_FKey_check(), RI_Initial_Check(), ri_PerformCheck(), ri_ReportViolation(), rollback_prepared_cb_wrapper(), RollbackToSavepoint(), rpad(), run_apply_worker(), sanity_check_array(), sanity_check_tid_array(), SanityCheckBackgroundWorker(), satisfies_hash_partition(), scanNameSpaceForRefname(), scanNameSpaceForRelid(), scanner_yyerror(), scanNSItemForColumn(), scanRTEForColumn(), scram_exchange(), scram_init(), secure_open_gssapi(), secure_read(), secure_write(), seg_yyerror(), select_common_collation(), select_common_type(), select_common_type_from_oids(), select_perl_context(), SendBaseBackup(), sendDir(), SendFunctionResult(), SendTimeLineHistory(), sepgsql_attribute_relabel(), sepgsql_avc_check_perms_label(), sepgsql_avc_init(), sepgsql_avc_unlabeled(), sepgsql_client_auth(), sepgsql_compute_avd(), sepgsql_compute_create(), sepgsql_get_label(), sepgsql_init_client_label(), sepgsql_mcstrans_in(), sepgsql_mcstrans_out(), sepgsql_object_relabel(), sepgsql_relation_relabel(), sepgsql_restorecon(), sepgsql_set_client_label(), sepgsql_utility_command(), serialize_expr_stats(), serialize_prepare_info(), server_check_detail(), set_config_by_name(), set_config_with_handle(), set_max_safe_fds(), set_var_from_non_decimal_integer_str(), set_var_from_str(), setCompoundAffixFlagValue(), SetDefaultACL(), setPath(), setPathArray(), setPathObject(), SetPossibleUnsafeConflict(), SetRWConflict(), setSchemaName(), setseed(), SetSerializableTransactionSnapshot(), setTargetTable(), SetTransactionSnapshot(), setup_background_workers(), setup_dynamic_shared_memory(), setup_pct_info(), setup_regexp_matches(), setup_test_matches(), SetUserIdAndContext(), SharedFileSetAttach(), shdepDropOwned(), shdepLockAndCheckObject(), shdepReassignOwned(), shell_check_detail(), shell_finish_command(), shell_get_sink(), shell_in(), shell_out(), shm_mq_receive(), shm_mq_sendv(), shm_toc_allocate(), shm_toc_insert(), ShmemAlloc(), ShmemAllocUnlocked(), ShmemInitStruct(), should_apply_changes_for_rel(), should_refetch_tuple(), similar_escape_internal(), SlabContextCreate(), slot_modify_data(), slot_store_data(), SnapBuildInitialSnapshot(), SnapBuildRestoreContents(), SnapBuildRestoreSnapshot(), socket_set_nonblocking(), SocketBackend(), sort(), spgadjustmembers(), spgdoinsert(), spgFormInnerTuple(), spgFormNodeTuple(), spgGetCache(), spgvalidate(), SPI_cursor_open_internal(), split_part(), sql_compile_callback(), sql_postrewrite_callback(), sqrt_var(), ssl_extension_info(), standard_ProcessUtility(), StandbySlotsHaveCaughtup(), StartBackgroundWorker(), StartChildProcess(), StartReplication(), StartupDecodingContext(), StartupReplicationOrigin(), StartupXLOG(), stats_check_arg_array(), stats_check_arg_pair(), stats_check_required_arg(), stats_lock_check_privileges(), stats_lookup_relid(), storeOperators(), StorePreparedStatement(), storeProcedures(), StoreRelCheck(), storeRow(), str_casefold(), str_initcap(), str_tolower(), str_toupper(), str_udeescape(), stream_abort_cb_wrapper(), stream_change_cb_wrapper(), stream_commit_cb_wrapper(), stream_prepare_cb_wrapper(), stream_start_cb_wrapper(), stream_stop_cb_wrapper(), string2ean(), string_to_privilege(), string_to_uuid(), stringToQualifiedNameList(), strlower_libc_mb(), strtitle_libc_mb(), strupper_libc_mb(), substitute_grouped_columns_mutator(), substitute_path_macro(), SummarizeWAL(), suppress_redundant_updates_trigger(), SV_to_JsonbValue(), SwitchToUntrustedUser(), synchronize_one_slot(), SyncRepWaitForLSN(), systable_beginscan_ordered(), systable_inplace_update_begin(), system_beginsamplescan(), system_rows_beginsamplescan(), system_time_beginsamplescan(), table_tuple_get_latest_tid(), tablesample_init(), TablespaceCreateDbspace(), TargetPrivilegesCheck(), tblspc_redo(), TerminateOtherDBBackends(), test_enc_conversion(), test_re_compile(), test_re_execute(), test_shm_mq(), test_shm_mq_main(), test_shm_mq_pipelined(), text_format(), text_format_append_string(), text_format_parse_digits(), text_format_parse_format(), text_format_string_conversion(), text_overlay(), text_starts_with(), text_substring(), text_to_bits(), text_to_stavalues(), textarray_to_strvaluelist(), textregexreplace(), textregexreplace_extended(), textToQualifiedNameList(), tfuncInitialize(), tfuncLoadRows(), thesaurus_init(), thesaurusRead(), throw_tcl_error(), tidin(), time_mi_interval(), time_part_common(), time_pl_interval(), time_recv(), timestamp2timestamptz_opt_overflow(), timestamp_age(), timestamp_bin(), timestamp_date(), timestamp_in(), timestamp_izone(), timestamp_mi(), timestamp_out(), timestamp_part_common(), timestamp_pl_interval(), timestamp_recv(), timestamp_time(), timestamp_to_char(), timestamp_trunc(), timestamp_zone(), timestamptz2timestamp(), timestamptz_age(), timestamptz_bin(), timestamptz_date(), timestamptz_in(), timestamptz_izone(), timestamptz_out(), timestamptz_part_common(), timestamptz_pl_interval_internal(), timestamptz_recv(), timestamptz_time(), timestamptz_timetz(), timestamptz_to_char(), timestamptz_trunc_internal(), timestamptz_zone(), timetz_izone(), timetz_mi_interval(), timetz_part_common(), timetz_pl_interval(), timetz_recv(), timetz_zone(), to_ascii_enc(), to_ascii_encname(), to_date(), to_json(), to_jsonb(), to_timestamp(), TopologicalSort(), tqueueReceiveSlot(), TransactionIdGetCommitTsData(), TransactionIdInRecentPast(), TransactionIdIsInProgress(), transformAExprNullIf(), transformAggregateCall(), transformAlterTableStmt(), transformArrayExpr(), transformAssignedExpr(), transformAssignmentIndirection(), transformAssignmentSubscripts(), transformCaseExpr(), transformCoalesceExpr(), transformCollateClause(), transformColumnDefinition(), transformColumnNameList(), transformColumnRef(), transformColumnType(), transformConstraintAttrs(), transformContainerSubscripts(), transformCreateStmt(), transformCreateTableAsStmt(), transformDeclareCursorStmt(), transformDistinctClause(), transformDistinctOnClause(), transformExprRecurse(), transformFkeyCheckAttrs(), transformFkeyGetPrimaryKey(), transformFrameOffset(), transformFromClauseItem(), transformGenericOptions(), transformGroupingFunc(), transformGroupingSet(), TransformGUCArray(), transformIndexConstraint(), transformIndexStmt(), transformIndirection(), transformInsertRow(), transformJsonAggConstructor(), transformJsonArrayQueryConstructor(), transformJsonBehavior(), transformJsonFuncExpr(), transformJsonIsPredicate(), transformJsonOutput(), transformJsonParseArg(), transformJsonParseExpr(), transformJsonReturning(), transformJsonSerializeExpr(), transformJsonTable(), transformJsonTableColumns(), transformJsonValueExpr(), transformLimitClause(), transformLockingClause(), transformMergeStmt(), transformMergeSupportFunc(), transformMultiAssignRef(), transformOnConflictArbiter(), transformParamRef(), transformPartitionBound(), transformPartitionBoundValue(), transformPartitionCmd(), transformPartitionRangeBounds(), transformPartitionSpec(), transformPLAssignStmt(), TransformPubWhereClauses(), transformRangeFunction(), transformRangeTableFunc(), transformRangeTableSample(), transformRelOptions(), transformReturningClause(), transformRowExpr(), transformRuleStmt(), transformSelectStmt(), transformSetOperationStmt(), transformSetOperationTree(), transformStatsStmt(), transformSubLink(), transformTableConstraint(), transformTableLikeClause(), transformTypeCast(), transformUpdateTargetList(), transformValuesClause(), transformWindowDefinitions(), transformWindowFuncCall(), transformWithClause(), transformXmlExpr(), transformXmlSerialize(), translate(), triggered_change_notification(), trim_array(), truncate_check_activity(), truncate_check_rel(), truncate_identifier(), tryAttachPartitionForeignKey(), ts_headline_byid_opt(), ts_headline_json_byid_opt(), ts_headline_jsonb_byid_opt(), ts_stat_sql(), tsquery_phrase_distance(), tsquery_rewrite_query(), tsvector_concat(), tsvector_filter(), tsvector_update_trigger(), tsvectorin(), ttdummy(), tts_buffer_heap_getsysattr(), tts_buffer_is_current_xact_tuple(), tts_heap_getsysattr(), tts_heap_is_current_xact_tuple(), tts_minimal_getsysattr(), tts_minimal_is_current_xact_tuple(), tts_virtual_getsysattr(), tts_virtual_is_current_xact_tuple(), tuple_data_split(), tuple_data_split_internal(), tupledesc_match(), tuples_equal(), TwoPhaseTransactionGid(), TypeCreate(), TypeGetTupleDesc(), typenameType(), typenameTypeMod(), TypeShellMake(), typeStringToTypeName(), uint32in_subr(), uint64in_subr(), unaccent_dict(), unaccent_init(), unicode_norm_form_from_string(), unique_key_recheck(), uniqueifyJsonbObject(), unistr(), unknown_attribute(), UserAbortTransactionBlock(), utf8_to_iso8859(), utf8_to_win(), UtfToLocal(), uuid_generate_internal(), vac_update_relstats(), vacuum(), vacuum_open_relation(), validate(), validate_ddl_tags(), validate_kvpair(), validate_option_array_item(), validate_pkattnums(), validate_relation_kind(), validate_remote_info(), validate_table_rewrite_tags(), validate_token_format(), validateConnectbyTupleDesc(), validateDomainCheckConstraint(), validateDomainNotNullConstraint(), validateFkOnDeleteSetColumns(), validateInfiniteBounds(), ValidateInputLSNs(), ValidateJoinEstimator(), ValidateOperatorReference(), ValidatePgVersion(), validateRecoveryParameters(), ValidateRestrictionEstimator(), ValidateSlotSyncParams(), varbit(), varbit_in(), varbit_recv(), varchar(), varchar_input(), variable_coerce_param_hook(), variable_paramref_hook(), varstr_levenshtein(), verify_brin_page(), verify_cb(), verify_dictoptions(), verify_gist_page(), verify_hash_page(), verify_heapam(), verifyBackupPageConsistency(), verifyPartitionIndexNotNull(), VirtualXactLock(), wait_for_workers_to_become_ready(), WaitEventCustomNew(), WaitForParallelWorkersToAttach(), WaitForParallelWorkersToExit(), WaitForParallelWorkersToFinish(), WaitForWalSummarization(), WalRcvFetchTimeLineHistoryFiles(), WALReadRaiseError(), WalReceiverMain(), widget_in(), width_bucket_array(), width_bucket_float8(), width_bucket_numeric(), win_to_utf8(), window_nth_value(), window_ntile(), worker_spi_launch(), write_auto_conf_file(), X509_NAME_field_to_text(), X509_NAME_to_cstring(), xlog_decode(), XLogFileCopy(), XLogPageRead(), XLogReadBufferForRedoExtended(), XlogReadTwoPhaseData(), XLogWalRcvProcessMsg(), xml_out_internal(), xmlcomment(), xmlpi(), XmlTableGetValue(), XmlTableSetColumnFilter(), XmlTableSetNamespace(), XmlTableSetRowFilter(), xmltotext_with_options(), xmlvalidate(), xpath_table(), and xslt_process().

◆ errcode_for_file_access()

int errcode_for_file_access ( void  )

Definition at line 877 of file elog.c.

878{
880
881 /* we don't bother incrementing recursion_depth */
883
884 switch (edata->saved_errno)
885 {
886 /* Permission-denied failures */
887 case EPERM: /* Not super-user */
888 case EACCES: /* Permission denied */
889#ifdef EROFS
890 case EROFS: /* Read only file system */
891#endif
892 edata->sqlerrcode = ERRCODE_INSUFFICIENT_PRIVILEGE;
893 break;
894
895 /* File not found */
896 case ENOENT: /* No such file or directory */
897 edata->sqlerrcode = ERRCODE_UNDEFINED_FILE;
898 break;
899
900 /* Duplicate file */
901 case EEXIST: /* File exists */
902 edata->sqlerrcode = ERRCODE_DUPLICATE_FILE;
903 break;
904
905 /* Wrong object type or state */
906 case ENOTDIR: /* Not a directory */
907 case EISDIR: /* Is a directory */
908 case ENOTEMPTY: /* Directory not empty */
909 edata->sqlerrcode = ERRCODE_WRONG_OBJECT_TYPE;
910 break;
911
912 /* Insufficient resources */
913 case ENOSPC: /* No space left on device */
914 edata->sqlerrcode = ERRCODE_DISK_FULL;
915 break;
916
917 case ENOMEM: /* Out of memory */
918 edata->sqlerrcode = ERRCODE_OUT_OF_MEMORY;
919 break;
920
921 case ENFILE: /* File table overflow */
922 case EMFILE: /* Too many open files */
923 edata->sqlerrcode = ERRCODE_INSUFFICIENT_RESOURCES;
924 break;
925
926 /* Hardware failure */
927 case EIO: /* I/O error */
928 edata->sqlerrcode = ERRCODE_IO_ERROR;
929 break;
930
931 case ENAMETOOLONG: /* File name too long */
932 edata->sqlerrcode = ERRCODE_FILE_NAME_TOO_LONG;
933 break;
934
935 /* All else is classified as internal errors */
936 default:
937 edata->sqlerrcode = ERRCODE_INTERNAL_ERROR;
938 break;
939 }
940
941 return 0; /* return value does not matter */
942}
int saved_errno
Definition: elog.h:447

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, ErrorData::saved_errno, and ErrorData::sqlerrcode.

Referenced by _mdfd_getseg(), _mdnblocks(), AddToDataDirLockFile(), AlterSystemSetConfigFile(), ApplyLogicalMappingFile(), apw_dump_now(), apw_load_buffers(), assign_wal_sync_method(), basebackup_read_file(), basic_archive_file(), bbsink_server_archive_contents(), bbsink_server_begin_archive(), bbsink_server_begin_manifest(), bbsink_server_end_archive(), bbsink_server_manifest_contents(), bbsink_server_new(), be_lo_export(), BeginCopyFrom(), BeginCopyTo(), BootStrapXLOG(), BufFileDumpBuffer(), BufFileLoadBuffer(), BufFileOpenFileSet(), BufFileReadCommon(), BufFileSeek(), BufFileSize(), BufFileTruncateFileSet(), calculate_relation_size(), calculate_tablespace_size(), ChangeToDataDir(), check_ssl_key_file_permissions(), checkDataDir(), CheckPointLogicalRewriteHeap(), CheckPointReplicationOrigin(), CheckPointSnapBuild(), CheckXLogRemoved(), ClosePipeFromProgram(), ClosePipeToProgram(), ClosePostmasterPorts(), compare_files(), copy_file(), copydir(), CopyGetData(), CopySendEndOfRow(), create_tablespace_directories(), CreateDirAndVersionFile(), CreateLockFile(), CreateOptsFile(), CreateSlotOnDisk(), db_dir_size(), DebugFileOpen(), DeleteAllExportedSnapshotFiles(), destroy_tablespace_directories(), do_pg_backup_stop(), do_truncate(), dsm_cleanup_for_mmap(), dsm_impl_mmap(), durable_rename(), durable_unlink(), EndCopy(), EndCopyFrom(), entry_reset(), errcode_for_dynamic_shared_memory(), ExecHashJoinNewBatch(), existsTimeLineHistory(), ExportSnapshot(), fileAnalyzeForeignTable(), FileClose(), fsync_fname_ext(), gc_qtexts(), get_controlfile_by_exact_path(), get_dirent_type(), GetConfFilesInDir(), getInstallationPaths(), hashagg_batch_read(), heap_xlog_logical_rewrite(), ImportSnapshot(), InitPostgres(), InitPostmasterDeathWatchHandle(), InitWalRecovery(), internal_load_library(), issue_xlog_fsync(), KeepFileRestoredFromArchive(), lo_import_internal(), load_dh_file(), logfile_open(), logical_end_heap_rewrite(), logical_heap_rewrite_flush_mappings(), logical_rewrite_log_mapping(), ltsReadBlock(), ltsWriteBlock(), md_readv_report(), mdcreate(), mdextend(), mdimmedsync(), mdopenfork(), mdreadv(), mdstartreadv(), mdtruncate(), mdunlinkfork(), mdwritev(), mdzeroextend(), normalize_exec_path(), open_auth_file(), OpenWalSummaryFile(), parse_extension_control_file(), ParseConfigFile(), PathNameCreateTemporaryDir(), PathNameCreateTemporaryFile(), PathNameDeleteTemporaryFile(), PathNameOpenTemporaryFile(), perform_base_backup(), pg_current_logfile(), pg_file_exists(), pg_flush_data(), pg_import_system_collations(), pg_ls_dir_files(), pg_promote(), pg_stat_file(), pg_tablespace_databases(), pg_tablespace_location(), pg_tzenumerate_next(), pg_tzenumerate_start(), pgarch_archiveDone(), pgarch_readyXlog(), PGReserveSemaphores(), PGSharedMemoryCreate(), pgss_shmem_shutdown(), pgss_shmem_startup(), pgstat_discard_stats(), pgstat_read_statsfile(), pgstat_write_statsfile(), pipe_read_line(), PostmasterMain(), PrepareRedoAdd(), ProcessSyncRequests(), qtext_load_file(), qtext_store(), read_backup_label(), read_binary_file(), read_relmap_file(), read_tablespace_map(), read_whole_file(), ReadControlFile(), ReadDirExtended(), ReadNextXLogRecord(), readRecoverySignalFile(), readTimeLineHistory(), ReadTwoPhaseFile(), ReadWalSummary(), RecheckDataDirLockFile(), RecreateTwoPhaseFile(), register_dirty_segment(), remove_tablespace_symlink(), RemovePgTempFilesInDir(), RemovePgTempRelationFilesInDbspace(), RemoveTwoPhaseFile(), RemoveWalSummaryIfOlderThan(), RemoveXlogFile(), ReorderBufferCleanupSerializedTXNs(), ReorderBufferRestoreChanges(), ReorderBufferRestoreCleanup(), ReorderBufferSerializeChange(), ReorderBufferSerializeTXN(), ReplicationSlotDropPtr(), ResetUnloggedRelationsInDbspaceDir(), ResetUnloggedRelationsInTablespaceDir(), RestoreArchivedFile(), RestoreSlotFromDisk(), run_ssl_passphrase_command(), SaveSlotToPath(), SendBackupManifest(), sendDir(), sendFile(), sendTablespace(), SendTimeLineHistory(), Setup_AF_UNIX(), shell_finish_command(), shell_run_command(), shell_send_data(), SlruReportIOError(), SnapBuildRestoreContents(), SnapBuildRestoreSnapshot(), SnapBuildSerialize(), SnapBuildSnapshotExists(), StartupReplicationOrigin(), sts_parallel_scan_next(), sts_read_tuple(), SummarizeWAL(), SyncDataDirectory(), SyncPostCheckpoint(), SysLogger_Start(), TablespaceCreateDbspace(), tokenize_auth_file(), tuplestore_copy_read_pointer(), tuplestore_gettuple(), tuplestore_puttuple_common(), tuplestore_rescan(), tuplestore_select_read_pointer(), unlink_if_exists_fname(), unlink_initfile(), update_controlfile(), update_metainfo_datafile(), ValidatePgVersion(), ValidateXLOGDirectoryStructure(), wal_segment_open(), WALReadRaiseError(), WalReceiverMain(), WalSndSegmentOpen(), write_auto_conf_file(), write_item(), write_relcache_init_file(), write_relmap_file(), WriteControlFile(), writeTimeLineHistory(), writeTimeLineHistoryFile(), WriteWalSummary(), XLogArchiveForceDone(), XLogArchiveNotify(), XLogFileClose(), XLogFileCopy(), XLogFileInit(), XLogFileInitInternal(), XLogFileOpen(), XLogFileRead(), XLogFileReadAnyTLI(), XLogInitNewTimeline(), XLogPageRead(), XlogReadTwoPhaseData(), XLogWalRcvClose(), XLogWalRcvWrite(), and XLogWrite().

◆ errcode_for_socket_access()

int errcode_for_socket_access ( void  )

Definition at line 954 of file elog.c.

955{
957
958 /* we don't bother incrementing recursion_depth */
960
961 switch (edata->saved_errno)
962 {
963 /* Loss of connection */
965 edata->sqlerrcode = ERRCODE_CONNECTION_FAILURE;
966 break;
967
968 /* All else is classified as internal errors */
969 default:
970 edata->sqlerrcode = ERRCODE_INTERNAL_ERROR;
971 break;
972 }
973
974 return 0; /* return value does not matter */
975}
#define ALL_CONNECTION_FAILURE_ERRNOS
Definition: port.h:122

References ALL_CONNECTION_FAILURE_ERRNOS, CHECK_STACK_DEPTH, errordata, errordata_stack_depth, ErrorData::saved_errno, and ErrorData::sqlerrcode.

Referenced by AcceptConnection(), auth_peer(), be_tls_open_server(), ident_inet(), InitPostmasterChild(), InitPostmasterDeathWatchHandle(), internal_flush_buffer(), ListenServerPort(), pq_getbyte_if_available(), pq_recvbuf(), ProcessStartupPacket(), SysLogger_Start(), SysLoggerMain(), and WaitEventSetWaitBlock().

◆ errcontext_msg()

int errcontext_msg ( const char *  fmt,
  ... 
)

Definition at line 1387 of file elog.c.

1388{
1390 MemoryContext oldcontext;
1391
1394 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1395
1396 EVALUATE_MESSAGE(edata->context_domain, context, true, true);
1397
1398 MemoryContextSwitchTo(oldcontext);
1400 return 0; /* return value does not matter */
1401}
#define EVALUATE_MESSAGE(domain, targetfield, appendval, translateit)
Definition: elog.c:990

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::context_domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), and recursion_depth.

◆ errdetail()

int errdetail ( const char *  fmt,
  ... 
)

Definition at line 1204 of file elog.c.

1205{
1207 MemoryContext oldcontext;
1208
1211 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1212
1213 EVALUATE_MESSAGE(edata->domain, detail, false, true);
1214
1215 MemoryContextSwitchTo(oldcontext);
1217 return 0; /* return value does not matter */
1218}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), and recursion_depth.

Referenced by _bt_check_third_page(), _bt_check_unique(), _PG_init(), AbortBufferIO(), AddEnumLabel(), AddRelationNotNullConstraints(), addUnicode(), addUnicodeChar(), AggregateCreate(), AllocSetContextCreateInternal(), AlterExtensionNamespace(), AlterPublicationOptions(), AlterPublicationSchemas(), AlterRole(), AlterRoleSet(), AlterTableNamespace(), apply_typmod(), apply_typmod_special(), array_cat(), array_fill_internal(), array_in(), array_set_slice(), assignable_custom_variable_name(), asyncQueueFillWarning(), ATAddForeignKeyConstraint(), ATExecAddColumn(), ATExecAddInherit(), ATExecAlterConstraint(), ATExecAttachPartition(), ATExecAttachPartitionIdx(), ATExecChangeOwner(), ATExecDropExpression(), ATExecSetExpression(), ATPrepAddPrimaryKey(), ATPrepAlterColumnType(), ATPrepChangePersistence(), AttachPartitionEnsureIndexes(), attribute_statistics_update(), BackendInitialize(), bbsink_server_new(), be_tls_init(), brin_page_type(), bt_entry_unique_check(), bt_page_items_bytea(), bt_report_duplicate(), buffer_readv_report(), build_attrmap_by_name(), build_attrmap_by_position(), BumpContextCreate(), check_av_worker_gucs(), check_conn_params(), check_encoding_locale_matches(), check_exclusion_or_unique_constraint(), check_lateral_ref_ok(), check_nested_generated_walker(), check_new_partition_bound(), check_object_ownership(), check_of_type(), check_password(), check_primary_key(), check_publication_add_relation(), check_publication_add_schema(), check_role_grantor(), check_role_membership_authorization(), check_sql_stmt_retval(), check_ssl_key_file_permissions(), check_valid_extension_name(), check_valid_version_name(), CheckAlterPublication(), CheckCmdReplicaIdentity(), checkDataDir(), checkMembershipInCurrentExtension(), CheckMyDatabase(), CheckPubRelationColumnList(), CheckRecoveryConflictDeadlock(), CheckRequiredParameterValues(), checkRuleResultList(), CheckSlotPermissions(), checkStringLen(), CheckTablespaceDirectory(), CheckVarSlotCompatibility(), clear_subscription_skip_lsn(), coerce_record_to_complex(), comparetup_index_btree_tiebreak(), compatConnectbyTupleDescs(), compatCrosstabTupleDescs(), compute_return_type(), ComputeIndexAttrs(), ComputePartitionAttrs(), copy_replication_slot(), copy_table_data(), CopyGetAttnums(), CopyReadAttributesCSV(), CopyReadAttributesText(), countVariablesFromJsonb(), create_distinct_paths(), create_ordinary_grouping_paths(), create_pg_locale(), createdb(), CreateDecodingContext(), CreateRestartPoint(), CreateRole(), CreateSchemaCommand(), CreateSubscription(), CreateTableSpace(), CreateTriggerFiringOn(), crosstab(), crosstab_hash(), cube_a_f8(), cube_a_f8_f8(), cube_c_f8(), cube_c_f8_f8(), cube_recv(), cube_subset(), cube_yyerror(), DateTimeParseError(), dblink_connstr_check(), dblink_fdw_validator(), dblink_security_check(), DCH_from_char(), DefineCollation(), DefineIndex(), DefineOpClass(), DefineOperator(), DefineRelation(), DeleteInheritsTuple(), DoCopy(), DropOwnedObjects(), DropRole(), dsa_allocate_extended(), dshash_create(), EnableLockPagesPrivilege(), encrypt_password(), enforce_generic_type_consistency(), enlargeStringInfo(), EnumValuesCreate(), errdetail_abort(), errdetail_busy_db(), errdetail_execute(), errdetail_params(), errdetail_recovery_conflict(), errdetail_relkind_not_supported(), error_multiple_recovery_targets(), errorMissingColumn(), errorMissingRTE(), EvaluateParams(), exec_move_row_from_fields(), exec_stmt_dynexecute(), exec_stmt_execsql(), ExecBRInsertTriggers(), ExecBuildUpdateProjection(), ExecCheckPlanOutput(), ExecConstraints(), ExecCrossPartitionUpdate(), ExecCrossPartitionUpdateForeignKey(), ExecEvalArrayExpr(), ExecEvalFieldSelect(), ExecEvalJsonCoercionFinish(), ExecEvalWholeRowVar(), ExecFindPartition(), ExecGrant_Language_check(), ExecPartitionCheckEmitError(), ExecWithCheckOptions(), expandTableLikeClause(), fatal_llvm_new_handler(), fatal_system_new_handler(), file_fdw_validator(), FindFKPeriodOpers(), finish_nodeitem(), FloatExceptionHandler(), from_char_parse_int_len(), from_char_seq_search(), from_char_set_int(), generate_nonunion_paths(), generate_recursion_path(), generateClonedIndexStmt(), GenerationContextCreate(), get_connect_string(), get_crosstab_tuplestore(), get_page_from_raw(), GetConfigOption(), GetConfigOptionByName(), GetConfigOptionResetString(), getid(), GetOperatorFromCompareType(), GetSerializableTransactionSnapshot(), GetSerializableTransactionSnapshotInt(), gin_leafpage_items(), gin_metapage_info(), gin_page_opaque_info(), gistdoinsert(), gistvacuumpage(), heap_create(), heap_truncate_check_FKs(), hlparsetext(), incompatible_module_error(), index_checkable(), InitializeMaxBackends(), InitPgFdwOptions(), InitPostgres(), InitWalRecovery(), InitXLogReaderState(), instantiate_empty_record_variable(), InternalIpcMemoryCreate(), InternalIpcSemaphoreCreate(), interval_trunc(), jsonb_set_lax(), lazy_check_wraparound_failsafe(), libpqrcv_check_conninfo(), libpqrcv_connect(), libpqrcv_identify_system(), libpqrcv_processTuples(), libpqrcv_readtimelinehistoryfile(), libpqsrv_connect_prepare(), load_categories_hash(), load_validator_library(), LoadArchiveLibrary(), LoadPublications(), LogChildExit(), ltxtq_out(), ltxtq_send(), make_pathkeys_for_window(), make_row_comparison_op(), makeMultirangeTypeName(), map_sql_value_to_xml_value(), MarkGUCPrefixReserved(), matchLocks(), MemoryContextAllocationFailure(), MergeAttributes(), MergeAttributesIntoExisting(), MergeChildAttribute(), MergeInheritedAttribute(), multirange_in(), namerecv(), network_in(), network_recv(), NUMDesc_prepare(), oauth_exchange(), parse_ident(), parse_kvpairs_for_auth(), parse_lquery(), parse_ltree(), parse_one_reloption(), parserOpenTable(), parsetext(), parseUnicode(), perform_default_encoding_conversion(), pg_cancel_backend(), pg_do_encoding_conversion(), pg_get_wal_record_info(), pg_get_wal_records_info_till_end_of_wal(), pg_get_wal_stats_till_end_of_wal(), pg_replication_origin_create(), pg_replication_slot_advance(), pg_size_bytes(), pg_terminate_backend(), pgfdw_security_check(), pgrowlocks(), PGSharedMemoryCreate(), pgstat_register_kind(), plpgsql_post_column_ref(), PLy_exec_function(), PLy_exec_trigger(), PLy_initialize(), PLyUnicode_ToComposite(), populate_array_check_dimension(), PrepareForIncrementalBackup(), PrepareRedoAdd(), preprocess_grouping_sets(), ProcedureCreate(), process_owned_by(), ProcessPgArchInterrupts(), ProcessStartupPacket(), ProcessUtilitySlow(), qtext_load_file(), queryin(), quickdie(), range_parse(), range_parse_bound(), read_any_attr(), read_attr_value(), read_backup_label(), read_client_final_message(), read_client_first_message(), ReadArrayDimensions(), ReadArrayStr(), ReadArrayToken(), ReadControlFile(), ReassignOwnedObjects(), record_in(), recordDependencyOnCurrentExtension(), RecoveryRequiresIntParameter(), refresh_by_match_merge(), refuseDupeIndexAttach(), RegisterCustomRmgr(), ReindexRelationConcurrently(), RememberAllDependentForRebuilding(), RemoveSubscriptionRel(), RenameEnumLabel(), RenameRole(), RenameSchema(), RenameTableSpace(), replace_percent_placeholders(), ReplicationSlotAcquire(), ReplicationSlotAlter(), ReplicationSlotDrop(), report_newlocale_failure(), ReportNotNullViolationError(), RestoreArchivedFile(), rewriteTargetListIU(), rewriteTargetView(), RI_FKey_check(), RI_Initial_Check(), ri_ReportViolation(), scram_exchange(), seg_yyerror(), set_max_safe_fds(), setPath(), SetTransactionSnapshot(), shell_archive_file(), should_apply_changes_for_rel(), SlabContextCreate(), SlruReportIOError(), SnapBuildFindSnapshot(), SnapBuildRestore(), SPI_cursor_open_internal(), sql_compile_callback(), standard_ProcessUtility(), StandbySlotsHaveCaughtup(), StartReplication(), StartupDecodingContext(), substitute_grouped_columns_mutator(), SummarizeWAL(), SyncRepWaitForLSN(), TerminateOtherDBBackends(), test_enc_conversion(), tfuncInitialize(), transformAggregateCall(), transformDeclareCursorStmt(), transformIndexConstraint(), transformJsonFuncExpr(), transformJsonTable(), transformMergeStmt(), TransformPubWhereClauses(), transformSetOperationStmt(), tupledesc_match(), update_and_persist_local_synced_slot(), update_local_synced_slot(), vac_cleanup_one_index(), vac_truncate_clog(), validate_kvpair(), validateConnectbyTupleDesc(), ValidateInputLSNs(), ValidatePgVersion(), variable_coerce_param_hook(), verify_brin_page(), verify_gist_page(), verify_hash_page(), verify_message(), verifyPartitionIndexNotNull(), WaitForWalSummarization(), WalReceiverMain(), write_relcache_init_file(), XlogReadTwoPhaseData(), xmlpi(), and xpath_table().

◆ errdetail_internal()

int errdetail_internal ( const char *  fmt,
  ... 
)

Definition at line 1231 of file elog.c.

1232{
1234 MemoryContext oldcontext;
1235
1238 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1239
1240 EVALUATE_MESSAGE(edata->domain, detail, false, false);
1241
1242 MemoryContextSwitchTo(oldcontext);
1244 return 0; /* return value does not matter */
1245}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), and recursion_depth.

Referenced by AggregateCreate(), be_tls_open_server(), bloom_get_procinfo(), bt_check_every_level(), bt_check_level_from_leftmost(), bt_child_check(), bt_child_highkey_check(), bt_downlink_missing_check(), bt_leftmost_ignoring_half_dead(), bt_recheck_sibling_links(), bt_right_page_check_scankey(), bt_target_page_check(), buffer_readv_report(), call_bool_check_hook(), call_enum_check_hook(), call_int_check_hook(), call_real_check_hook(), call_string_check_hook(), check_rolespec_name(), check_simple_rowfilter_expr_walker(), CheckForSerializableConflictIn(), CheckForSerializableConflictOut(), CheckForSerializableConflictOutNeeded(), ClosePipeFromProgram(), ClosePipeToProgram(), connect_pg_server(), dblink_connect(), dblink_get_conn(), dblink_res_error(), DeadLockReport(), DropRole(), DropTableSpace(), elog_node_display(), error_view_not_updatable(), exec_stmt_dynexecute(), exec_stmt_execsql(), exec_stmt_raise(), FreezeMultiXactId(), GetConnection(), inclusion_get_procinfo(), incompatible_module_error(), json_errsave_error(), minmax_multi_get_procinfo(), OnConflict_CheckForSerializationFailure(), PageGetItemIdCareful(), parse_one_reloption(), pg_GSS_error(), pgarch_ArchiverCopyLoop(), pgfdw_report_error(), PLy_elog_impl(), PLy_output(), PreCommit_CheckForSerializationFailure(), ProcedureCreate(), reindex_index(), ReportApplyConflict(), reportDependentObjects(), ReportSlotInvalidation(), rewriteTargetView(), run_ssl_passphrase_command(), shell_finish_command(), ShowUsage(), SnapBuildFindSnapshot(), sts_read_tuple(), synchronize_one_slot(), update_local_synced_slot(), XLogRecordAssemble(), XLogRegisterBufData(), and XLogRegisterData().

◆ errdetail_log()

int errdetail_log ( const char *  fmt,
  ... 
)

◆ errdetail_log_plural()

int errdetail_log_plural ( const char *  fmt_singular,
const char *  fmt_plural,
unsigned long  n,
  ... 
)

Definition at line 1273 of file elog.c.

1275{
1277 MemoryContext oldcontext;
1278
1281 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1282
1283 EVALUATE_MESSAGE_PLURAL(edata->domain, detail_log, false);
1284
1285 MemoryContextSwitchTo(oldcontext);
1287 return 0; /* return value does not matter */
1288}
#define EVALUATE_MESSAGE_PLURAL(domain, targetfield, appendval)
Definition: elog.c:1026

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE_PLURAL, MemoryContextSwitchTo(), and recursion_depth.

Referenced by LockAcquireExtended(), LogRecoveryConflict(), and ProcSleep().

◆ errdetail_plural()

int errdetail_plural ( const char *  fmt_singular,
const char *  fmt_plural,
unsigned long  n,
  ... 
)

◆ errfinish()

void errfinish ( const char *  filename,
int  lineno,
const char *  funcname 
)

Definition at line 474 of file elog.c.

475{
477 int elevel;
478 MemoryContext oldcontext;
479 ErrorContextCallback *econtext;
480
483
484 /* Save the last few bits of error state into the stack entry */
486
487 elevel = edata->elevel;
488
489 /*
490 * Do processing in ErrorContext, which we hope has enough reserved space
491 * to report an error.
492 */
494
495 /* Collect backtrace, if enabled and we didn't already */
496 if (!edata->backtrace &&
497 edata->funcname &&
500 set_backtrace(edata, 2);
501
502 /*
503 * Call any context callback functions. Errors occurring in callback
504 * functions will be treated as recursive errors --- this ensures we will
505 * avoid infinite recursion (see errstart).
506 */
507 for (econtext = error_context_stack;
508 econtext != NULL;
509 econtext = econtext->previous)
510 econtext->callback(econtext->arg);
511
512 /*
513 * If ERROR (not more nor less) we pass it off to the current handler.
514 * Printing it and popping the stack is the responsibility of the handler.
515 */
516 if (elevel == ERROR)
517 {
518 /*
519 * We do some minimal cleanup before longjmp'ing so that handlers can
520 * execute in a reasonably sane state.
521 *
522 * Reset InterruptHoldoffCount in case we ereport'd from inside an
523 * interrupt holdoff section. (We assume here that no handler will
524 * itself be inside a holdoff section. If necessary, such a handler
525 * could save and restore InterruptHoldoffCount for itself, but this
526 * should make life easier for most.)
527 */
530
531 CritSectionCount = 0; /* should be unnecessary, but... */
532
533 /*
534 * Note that we leave CurrentMemoryContext set to ErrorContext. The
535 * handler should reset it to something else soon.
536 */
537
539 PG_RE_THROW();
540 }
541
542 /* Emit the message to the right places */
544
545 /* Now free up subsidiary data attached to stack entry, and release it */
548
549 /* Exit error-handling context */
550 MemoryContextSwitchTo(oldcontext);
552
553 /*
554 * Perform error recovery action as specified by elevel.
555 */
556 if (elevel == FATAL)
557 {
558 /*
559 * For a FATAL error, we let proc_exit clean up and exit.
560 *
561 * If we just reported a startup failure, the client will disconnect
562 * on receiving it, so don't send any more to the client.
563 */
566
567 /*
568 * fflush here is just to improve the odds that we get to see the
569 * error message, in case things are so hosed that proc_exit crashes.
570 * Any other code you might be tempted to add here should probably be
571 * in an on_proc_exit or on_shmem_exit callback instead.
572 */
573 fflush(NULL);
574
575 /*
576 * Let the cumulative stats system know. Only mark the session as
577 * terminated by fatal error if there is no other known cause.
578 */
581
582 /*
583 * Do normal process-exit cleanup, then return exit code 1 to indicate
584 * FATAL termination. The postmaster may or may not consider this
585 * worthy of panic, depending on which subprocess returns it.
586 */
587 proc_exit(1);
588 }
589
590 if (elevel >= PANIC)
591 {
592 /*
593 * Serious crash time. Postmaster will observe SIGABRT process exit
594 * status and kill the other backends too.
595 *
596 * XXX: what if we are *in* the postmaster? abort() won't kill our
597 * children...
598 */
599 fflush(NULL);
600 abort();
601 }
602
603 /*
604 * Check for cancel/die interrupt first --- this is so that the user can
605 * stop a query emitting tons of notice or warning messages, even if it's
606 * in a loop that otherwise fails to check for interrupts.
607 */
609}
@ DestRemote
Definition: dest.h:89
@ DestNone
Definition: dest.h:87
void EmitErrorReport(void)
Definition: elog.c:1709
static void FreeErrorDataContents(ErrorData *edata)
Definition: elog.c:1852
ErrorContextCallback * error_context_stack
Definition: elog.c:95
static bool matches_backtrace_functions(const char *funcname)
Definition: elog.c:826
static void set_stack_entry_location(ErrorData *edata, const char *filename, int lineno, const char *funcname)
Definition: elog.c:796
sigjmp_buf * PG_exception_stack
Definition: elog.c:97
#define PG_RE_THROW()
Definition: elog.h:405
#define PANIC
Definition: elog.h:42
volatile uint32 QueryCancelHoldoffCount
Definition: globals.c:44
volatile uint32 InterruptHoldoffCount
Definition: globals.c:43
volatile uint32 CritSectionCount
Definition: globals.c:45
char * backtrace_functions
Definition: guc_tables.c:536
#define funcname
Definition: indent_codes.h:69
void proc_exit(int code)
Definition: ipc.c:104
#define CHECK_FOR_INTERRUPTS()
Definition: miscadmin.h:122
static char * filename
Definition: pg_dumpall.c:125
@ DISCONNECT_FATAL
Definition: pgstat.h:57
@ DISCONNECT_NORMAL
Definition: pgstat.h:55
SessionEndType pgStatSessionEndCause
CommandDest whereToSendOutput
Definition: postgres.c:91
struct ErrorContextCallback * previous
Definition: elog.h:297
void(* callback)(void *arg)
Definition: elog.h:298

References ErrorContextCallback::arg, ErrorData::backtrace, backtrace_functions, ErrorContextCallback::callback, CHECK_FOR_INTERRUPTS, CHECK_STACK_DEPTH, CritSectionCount, DestNone, DestRemote, DISCONNECT_FATAL, DISCONNECT_NORMAL, ErrorData::elevel, EmitErrorReport(), ERROR, error_context_stack, ErrorContext, errordata, errordata_stack_depth, FATAL, filename, FreeErrorDataContents(), ErrorData::funcname, funcname, InterruptHoldoffCount, matches_backtrace_functions(), MemoryContextSwitchTo(), PANIC, PG_exception_stack, PG_RE_THROW, pgStatSessionEndCause, ErrorContextCallback::previous, proc_exit(), QueryCancelHoldoffCount, recursion_depth, set_backtrace(), set_stack_entry_location(), and whereToSendOutput.

Referenced by errsave_finish(), pg_re_throw(), and ThrowErrorData().

◆ errhidecontext()

int errhidecontext ( bool  hide_ctx)

Definition at line 1452 of file elog.c.

1453{
1455
1456 /* we don't bother incrementing recursion_depth */
1458
1459 edata->hide_ctx = hide_ctx;
1460
1461 return 0; /* return value does not matter */
1462}
bool hide_ctx
Definition: elog.h:425

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::hide_ctx.

Referenced by buffer_call_start_io(), buffer_call_terminate_io(), llvm_compile_module(), MemoryContextStatsDetail(), MemoryContextStatsInternal(), MemoryContextStatsPrint(), and ProcessLogMemoryContextInterrupt().

◆ errhidestmt()

int errhidestmt ( bool  hide_stmt)

Definition at line 1433 of file elog.c.

1434{
1436
1437 /* we don't bother incrementing recursion_depth */
1439
1440 edata->hide_stmt = hide_stmt;
1441
1442 return 0; /* return value does not matter */
1443}

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::hide_stmt.

Referenced by buffer_call_start_io(), buffer_call_terminate_io(), exec_bind_message(), exec_execute_message(), exec_parse_message(), exec_simple_query(), explain_ExecutorEnd(), llvm_compile_module(), MemoryContextStatsDetail(), MemoryContextStatsInternal(), MemoryContextStatsPrint(), and ProcessLogMemoryContextInterrupt().

◆ errhint()

int errhint ( const char *  fmt,
  ... 
)

Definition at line 1318 of file elog.c.

1319{
1321 MemoryContext oldcontext;
1322
1325 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1326
1327 EVALUATE_MESSAGE(edata->domain, hint, false, true);
1328
1329 MemoryContextSwitchTo(oldcontext);
1331 return 0; /* return value does not matter */
1332}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), and recursion_depth.

Referenced by _bt_check_third_page(), _bt_check_unique(), _bt_checkpage(), _bt_pagedel(), _hash_checkpage(), _hash_doinsert(), aclparse(), addTargetToSortList(), AdjustNotNullInheritance(), AlterCollation(), AlterDatabase(), AlterEventTriggerOwner_internal(), AlterForeignDataWrapper(), AlterForeignDataWrapperOwner_internal(), AlterObjectRename_internal(), AlterPublicationOwner_internal(), AlterSubscription(), AlterSubscriptionOwner_internal(), AlterTypeNamespace_oid(), AlterTypeNamespaceInternal(), AlterTypeOwner(), analyzeCTE(), apw_start_database_worker(), apw_start_leader_worker(), assign_collations_walker(), assign_hypothetical_collations(), assignProcTypes(), asyncQueueFillWarning(), AtEOSubXact_SPI(), AtEOXact_SPI(), ATExecAddIdentity(), ATExecAlterConstraint(), ATExecChangeOwner(), ATExecColumnDefault(), ATExecDropColumn(), ATExecDropIdentity(), ATExecSetIdentity(), ATExecSetNotNull(), ATExecSetRelOptions(), ATExecSetStatistics(), ATPrepAddPrimaryKey(), ATPrepAlterColumnType(), ATPrepCmd(), attribute_statistics_update(), autovac_init(), BackendInitialize(), bbsink_server_archive_contents(), bbsink_server_manifest_contents(), be_tls_open_server(), BeginCopyFrom(), BeginCopyTo(), brin_desummarize_range(), brin_page_items(), brin_summarize_range(), bt_check_every_level(), bt_entry_unique_check(), bt_index_check_callback(), bt_metap(), bt_target_page_check(), bt_tuple_present_callback(), buffer_readv_report(), build_column_default(), call_bool_check_hook(), call_enum_check_hook(), call_int_check_hook(), call_real_check_hook(), call_string_check_hook(), char2wchar(), check_agg_arguments_walker(), check_collation_set(), check_enable_rls(), check_escape_warning(), check_index_page(), check_lateral_ref_ok(), check_publications_origin(), check_safe_enum_use(), check_stack_depth(), check_string_escape_warning(), CheckAttributeType(), CheckCmdReplicaIdentity(), checkDataDir(), CheckForSerializableConflictIn(), CheckForSerializableConflictOut(), CheckForSerializableConflictOutNeeded(), checkJsonOutputFormat(), CheckMyDatabase(), CheckpointerMain(), CheckRequiredParameterValues(), CheckTablespaceDirectory(), checkTimezoneIsUsedForCast(), checkViewColumns(), compileTheLexeme(), ComputeIndexAttrs(), ComputePartitionAttrs(), cookDefault(), copy_replication_slot(), CopyFrom(), CopyReadLineText(), create_ctas_nodata(), create_pg_locale(), create_tablespace_directories(), CreateAccessMethod(), CreateAnonymousSegment(), createdb(), CreateDecodingContext(), CreateEventTrigger(), CreateForeignDataWrapper(), CreateFunction(), CreateLockFile(), CreatePredicateLock(), CreatePublication(), CreateSubscription(), CreateTableSpace(), CreateTriggerFiringOn(), DateTimeParseError(), dblink_fdw_validator(), dblink_res_error(), dblink_security_check(), DeadLockReport(), DefineQueryRewrite(), DefineRange(), DefineType(), DefineView(), DefineVirtualRelation(), DeleteInheritsTuple(), do_pg_backup_start(), do_pg_backup_stop(), do_to_timestamp(), DoCopy(), DoPortalRewind(), DropErrorMsgWrongType(), EnableLockPagesPrivilege(), encrypt_password(), error_commit_ts_disabled(), error_view_not_updatable(), errorMissingColumn(), errorMissingRTE(), EvaluateParams(), exec_move_row_from_fields(), exec_stmt_case(), exec_stmt_dynexecute(), exec_stmt_execsql(), exec_stmt_raise(), ExecCrossPartitionUpdateForeignKey(), ExecDelete(), ExecGrant_Type_check(), ExecMergeMatched(), ExecOnConflictUpdate(), ExecOpenScanRelation(), ExecUpdate(), execute_extension_script(), executeDateTimeMethod(), ExecuteDoStmt(), ExecuteTruncate(), ExecVacuum(), ExitPostmaster(), ExtendBufferedRelShared(), FastPathGetRelationLockEntry(), fetch_finfo_record(), file_fdw_validator(), find_typed_table_dependencies(), findDependentObjects(), findRangeSubOpclass(), forkname_to_number(), from_char_parse_int_len(), from_char_set_mode(), Generic_Text_IC_like(), GenericMatchText(), get_object_address_defacl(), get_raw_page(), get_record_type_from_query(), get_required_extension(), get_sort_group_operators(), getInstallationPaths(), GetNewMultiXactId(), GetNewTransactionId(), GetSerializableTransactionSnapshot(), GetTupleForTrigger(), gin_clean_pending_list(), ginCombineData(), gistcheckpage(), gistdoinsert(), gistUserPicksplit(), gistvacuumpage(), hashbpchar(), hashbpcharextended(), hashtext(), hashtextextended(), heap_create_with_catalog(), heap_force_common(), heap_truncate_check_FKs(), icu_validate_locale(), initialize_ecdh(), InitPostgres(), InitWalRecovery(), internal_load_library(), InternalIpcMemoryCreate(), InternalIpcSemaphoreCreate(), intorel_startup(), IpcSemaphoreInitialize(), json_build_object_worker(), jsonb_build_object_worker(), jsonb_set_lax(), jsonb_subscript_transform(), JsonPathQuery(), lazy_check_wraparound_failsafe(), libpqrcv_connect(), libpqsrv_connect_prepare(), like_fixed_prefix(), ListenServerPort(), LoadPublications(), lock_twophase_recover(), LockAcquireExtended(), LockGXact(), LogChildExit(), logicalrep_worker_launch(), LookupFuncName(), LookupFuncWithArgs(), macaddr8tomacaddr(), make_row_comparison_op(), makeMultirangeTypeName(), MarkAsPreparing(), MarkInheritDetached(), mdextend(), mdwritev(), mdzeroextend(), MergeAttributes(), MergeChildAttribute(), movedb(), OnConflict_CheckForSerializationFailure(), op_error(), palloc_btree_page(), parse_and_validate_value(), parse_extension_control_file(), parse_hba_line(), parse_jsonb_index_flags(), parse_sane_timezone(), ParseFuncOrColumn(), parserOpenTable(), partitioned_table_reloptions(), pg_backup_stop(), pg_base64_decode(), pg_clear_attribute_stats(), pg_create_restore_point(), pg_current_logfile(), pg_current_wal_flush_lsn(), pg_current_wal_insert_lsn(), pg_current_wal_lsn(), pg_get_wal_replay_pause_state(), pg_is_wal_replay_paused(), pg_log_standby_snapshot(), pg_prewarm(), pg_promote(), pg_set_regex_collation(), pg_size_bytes(), pg_stat_reset_shared(), pg_switch_wal(), pg_wal_replay_pause(), pg_wal_replay_resume(), pg_walfile_name(), pg_walfile_name_offset(), pgfdw_report_error(), pgfdw_security_check(), PGSharedMemoryCreate(), pgstat_register_kind(), plan_recursive_revoke(), plpgsql_compile_callback(), PLy_elog_impl(), PLy_output(), PLyGenericObject_ToComposite(), PLyMapping_ToComposite(), PLyUnicode_ToComposite(), policy_role_list_to_array(), populate_array_report_expected_array(), PortalRunSelect(), postgres_fdw_validator(), postgresql_fdw_validator(), PostmasterMain(), PreCommit_CheckForSerializationFailure(), PrepareForIncrementalBackup(), PrepareRedoAdd(), ProcedureCreate(), process_owned_by(), process_postgres_switches(), ProcessRecoveryConflictInterrupt(), ProcessStartupPacket(), px_crypt_shacrypt(), quickdie(), range_parse_flags(), RangeVarCallbackForAlterRelation(), read_backup_label(), ReadControlFile(), readTimeLineHistory(), recoveryPausesHere(), RecoveryRequiresIntParameter(), recursive_revoke(), RefreshMatViewByOid(), regexp_match(), RegisterBackgroundWorker(), RegisterCustomRmgr(), regoperatorin(), ReindexRelationConcurrently(), relation_statistics_update(), ReleaseOneSerializableXact(), RemoveObjects(), RemoveSubscriptionRel(), renametrig(), RenameType(), ReplicationSlotCreate(), ReplicationSlotValidateName(), replorigin_advance(), replorigin_session_setup(), reportDependentObjects(), ReportSlotConnectionError(), ReportSlotInvalidation(), RequestCheckpoint(), ResolveOpClass(), RestoreSlotFromDisk(), RewriteQuery(), rewriteTargetListIU(), rewriteTargetView(), ri_FetchConstraintInfo(), ri_PerformCheck(), RmgrNotFound(), select_common_collation(), sendDir(), SetMultiXactIdLimit(), setPathObject(), SetPossibleUnsafeConflict(), SetRWConflict(), SetTransactionIdLimit(), setup_background_workers(), shell_archive_file(), shell_get_sink(), similar_escape_internal(), spgdoinsert(), spgFormInnerTuple(), StandbySlotsHaveCaughtup(), StartupXLOG(), stats_fill_fcinfo_from_arg_pairs(), str_casefold(), str_initcap(), str_tolower(), str_toupper(), str_udeescape(), SysLogger_Start(), tblspc_redo(), text_format(), textregexreplace(), transformArrayExpr(), transformAssignedExpr(), transformAssignmentIndirection(), transformCaseExpr(), transformCoalesceExpr(), transformFrameOffset(), transformInsertRow(), transformJsonBehavior(), transformJsonReturning(), transformJsonSerializeExpr(), transformOnConflictArbiter(), transformPLAssignStmt(), transformRangeFunction(), transformSetOperationStmt(), transformUpdateTargetList(), transformWindowDefinitions(), unistr(), vacuum_get_cutoffs(), validate_remote_info(), ValidatePgVersion(), validateRecoveryParameters(), verify_heapam(), VirtualXactLock(), WaitForParallelWorkersToAttach(), WaitForParallelWorkersToFinish(), worker_spi_launch(), and WriteWalSummary().

◆ errhint_internal()

int errhint_internal ( const char *  fmt,
  ... 
)

Definition at line 1340 of file elog.c.

1341{
1343 MemoryContext oldcontext;
1344
1347 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1348
1349 EVALUATE_MESSAGE(edata->domain, hint, false, false);
1350
1351 MemoryContextSwitchTo(oldcontext);
1353 return 0; /* return value does not matter */
1354}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), and recursion_depth.

Referenced by buffer_readv_report().

◆ errhint_plural()

int errhint_plural ( const char *  fmt_singular,
const char *  fmt_plural,
unsigned long  n,
  ... 
)

Definition at line 1361 of file elog.c.

1363{
1365 MemoryContext oldcontext;
1366
1369 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1370
1371 EVALUATE_MESSAGE_PLURAL(edata->domain, hint, false);
1372
1373 MemoryContextSwitchTo(oldcontext);
1375 return 0; /* return value does not matter */
1376}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE_PLURAL, MemoryContextSwitchTo(), and recursion_depth.

Referenced by ParseFuncOrColumn().

◆ errmsg()

int errmsg ( const char *  fmt,
  ... 
)

Definition at line 1071 of file elog.c.

1072{
1074 MemoryContext oldcontext;
1075
1078 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1079
1080 edata->message_id = fmt;
1081 EVALUATE_MESSAGE(edata->domain, message, false, true);
1082
1083 MemoryContextSwitchTo(oldcontext);
1085 return 0; /* return value does not matter */
1086}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), ErrorData::message_id, and recursion_depth.

Referenced by _arrq_cons(), _bt_check_third_page(), _bt_check_unique(), _bt_checkpage(), _bt_getmeta(), _bt_gettrueroot(), _bt_pagedel(), _crypt_blowfish_rn(), _crypt_gensalt_sha(), _hash_addovflpage(), _hash_checkpage(), _hash_doinsert(), _hash_first(), _hash_init(), _hash_ovflblkno_to_bitno(), _intbig_in(), _intbig_out(), _lca(), _lt_q_regex(), _ltree_compress(), _mdfd_getseg(), _mdnblocks(), _PG_init(), _SPI_commit(), _SPI_execute_plan(), _SPI_rollback(), _tarWriteHeader(), AbortBufferIO(), AcceptConnection(), accumArrayResult(), accumArrayResultArr(), aclcheck_error(), aclcheck_error_col(), aclinsert(), aclitemin(), aclparse(), aclremove(), acquire_inherited_sample_rows(), acquire_sample_rows(), add_guc_variable(), add_json(), add_jsonb(), add_parameter_name(), add_reloption_kind(), add_size(), addCompoundAffixFlagValue(), AddEnumLabel(), addFamilyMember(), addFkConstraint(), addFkRecurseReferencing(), AddQual(), addRangeTableEntryForCTE(), addRangeTableEntryForFunction(), addRangeTableEntryForJoin(), addRangeTableEntryForSubquery(), addRangeTableEntryForTableFunc(), addRangeTableEntryForValues(), AddRelationNewConstraints(), AddRelationNotNullConstraints(), AddRoleMems(), addTargetToSortList(), AddToDataDirLockFile(), addUnicode(), addUnicodeChar(), AddWALInfoToBackupManifest(), AdjustIntervalForTypmod(), AdjustNotNullInheritance(), AdjustTimestampForTypmod(), advance_windowaggregate(), afterTriggerMarkEvents(), AfterTriggerSetState(), AggregateCreate(), alen_object_start(), alen_scalar(), AllocateDir(), AllocateFile(), AllocateVfd(), AllocSetContextCreateInternal(), AlterCollation(), AlterDatabase(), AlterDatabaseOwner(), AlterDatabaseRefreshColl(), AlterDomainDropConstraint(), AlterDomainValidateConstraint(), AlterEventTrigger(), AlterEventTriggerOwner(), AlterEventTriggerOwner_internal(), AlterEventTriggerOwner_oid(), AlterExtensionNamespace(), AlterForeignDataWrapper(), AlterForeignDataWrapperOwner(), AlterForeignDataWrapperOwner_internal(), AlterForeignDataWrapperOwner_oid(), AlterForeignServer(), AlterForeignServerOwner(), AlterForeignServerOwner_oid(), AlterFunction(), AlterObjectNamespace_internal(), AlterObjectRename_internal(), AlterOperator(), AlterOpFamily(), AlterOpFamilyAdd(), AlterOpFamilyDrop(), AlterPolicy(), AlterPublication(), AlterPublicationOptions(), AlterPublicationOwner(), AlterPublicationOwner_internal(), AlterPublicationOwner_oid(), AlterPublicationSchemas(), AlterRelationNamespaceInternal(), AlterReplicationSlot(), AlterRole(), AlterRoleSet(), AlterSchemaOwner(), AlterSequence(), AlterStatistics(), AlterSubscription(), AlterSubscription_refresh(), AlterSubscriptionOwner(), AlterSubscriptionOwner_internal(), AlterSubscriptionOwner_oid(), AlterSystemSetConfigFile(), AlterTableMoveAll(), AlterTableNamespace(), AlterTableSpaceOptions(), AlterTSConfiguration(), AlterType(), AlterTypeNamespace(), AlterTypeNamespace_oid(), AlterTypeNamespaceInternal(), AlterTypeOwner(), AlterTypeOwnerInternal(), AlterUserMapping(), amcheck_index_mainfork_expected(), amcheck_lock_relation_and_check(), analyze_rel(), analyzeCTE(), analyzeCTETargetList(), anybit_typmodin(), anychar_typmodin(), anytime_typmod_check(), anytime_typmodin(), anytimestamp_typmod_check(), anytimestamp_typmodin(), appendElement(), appendKey(), apply_dispatch(), apply_typmod(), apply_typmod_special(), ApplyLogicalMappingFile(), ApplyRetrieveRule(), apw_dump_now(), apw_load_buffers(), apw_start_database_worker(), apw_start_leader_worker(), array_agg_array_combine(), array_agg_array_transfn(), array_agg_deserialize(), array_agg_transfn(), array_append(), array_cat(), array_cmp(), array_contain_compare(), array_eq(), array_exec_setup(), array_fill(), array_fill_internal(), array_fill_with_lower_bounds(), array_get_slice(), array_in(), array_iterator(), array_map(), array_position_common(), array_positions(), array_prepend(), array_recv(), array_replace_internal(), array_sample(), array_send(), array_set_element(), array_set_element_expanded(), array_set_slice(), array_sort_internal(), array_subscript_check_subscripts(), array_subscript_transform(), array_to_datum_internal(), array_to_tsvector(), ArrayCheckBoundsSafe(), ArrayGetIntegerTypmods(), ArrayGetNItemsSafe(), arrq_cons(), ascii(), ASN1_STRING_to_text(), assign_collations_walker(), assign_hypothetical_collations(), assign_record_type_identifier(), assign_wal_sync_method(), assignable_custom_variable_name(), assignOperTypes(), assignProcTypes(), AssignTransactionId(), AssignTypeArrayOid(), AssignTypeMultirangeArrayOid(), AssignTypeMultirangeOid(), Async_Notify(), asyncQueueFillWarning(), ATAddCheckNNConstraint(), ATAddForeignKeyConstraint(), AtEOSubXact_SPI(), AtEOXact_SPI(), ATExecAddColumn(), ATExecAddConstraint(), ATExecAddIdentity(), ATExecAddIndexConstraint(), ATExecAddInherit(), ATExecAddOf(), ATExecAlterColumnGenericOptions(), ATExecAlterColumnType(), ATExecAlterConstraint(), ATExecAttachPartition(), ATExecAttachPartitionIdx(), ATExecChangeOwner(), ATExecClusterOn(), ATExecColumnDefault(), ATExecDetachPartition(), ATExecDropColumn(), ATExecDropConstraint(), ATExecDropExpression(), ATExecDropIdentity(), ATExecDropInherit(), ATExecDropNotNull(), ATExecDropOf(), ATExecGenericOptions(), ATExecReplicaIdentity(), ATExecSetCompression(), ATExecSetExpression(), ATExecSetIdentity(), ATExecSetNotNull(), ATExecSetOptions(), ATExecSetRelOptions(), ATExecSetStatistics(), ATExecSetStorage(), ATExecValidateConstraint(), ATPrepAddColumn(), ATPrepAddInherit(), ATPrepAddPrimaryKey(), ATPrepAlterColumnType(), AtPrepare_Locks(), AtPrepare_Notify(), AtPrepare_RelationMap(), ATPrepChangePersistence(), ATPrepCmd(), ATPrepDropColumn(), ATPrepDropExpression(), ATPrepSetTableSpace(), ATRewriteTable(), ATRewriteTables(), ATSimplePermissions(), AtSubCommit_childXids(), attach_internal(), AttachPartitionEnsureIndexes(), attribute_statistics_update(), auth_failed(), auth_peer(), autoinc(), autoprewarm_database_main(), autoprewarm_main(), autoprewarm_start_worker(), autovac_init(), AutoVacLauncherMain(), BackendInitialize(), BackendMain(), BackendStartup(), BackgroundWorkerInitializeConnection(), BackgroundWorkerInitializeConnectionByOid(), BackgroundWorkerStateChange(), basebackup_read_file(), BaseBackupGetTargetHandle(), basic_archive_file(), BasicOpenFilePerm(), bbsink_gzip_new(), bbsink_lz4_new(), bbsink_server_archive_contents(), bbsink_server_begin_archive(), bbsink_server_begin_manifest(), bbsink_server_end_archive(), bbsink_server_manifest_contents(), bbsink_server_new(), bbsink_zstd_new(), be_gssapi_read(), be_gssapi_write(), be_lo_close(), be_lo_export(), be_lo_get_fragment(), be_lo_lseek(), be_lo_lseek64(), be_lo_tell(), be_lo_tell64(), be_lo_unlink(), be_tls_init(), be_tls_open_server(), be_tls_read(), be_tls_write(), begin_prepare_cb_wrapper(), BeginCopyFrom(), BeginCopyTo(), BeginTransactionBlock(), bernoulli_beginsamplescan(), bgworker_die(), binary_decode(), binary_encode(), bit(), bit_and(), bit_catenate(), bit_in(), bit_or(), bit_overlay(), bit_recv(), bitgetbit(), bitsetbit(), bitsubstring(), bittoint4(), bittoint8(), bitxor(), blvalidate(), boolin(), BootstrapModeMain(), BootStrapXLOG(), bpchar(), bpchar_input(), bqarr_in(), bqarr_out(), brin_bloom_summary_in(), brin_bloom_summary_recv(), brin_desummarize_range(), brin_doinsert(), brin_doupdate(), brin_getinsertbuffer(), brin_metapage_info(), brin_minmax_multi_summary_in(), brin_minmax_multi_summary_recv(), brin_page_items(), brin_page_type(), brin_revmap_data(), brin_summarize_range(), brininsert(), brinRevmapDesummarizeRange(), brinvalidate(), bt_check_every_level(), bt_check_level_from_leftmost(), bt_child_check(), bt_child_highkey_check(), bt_downlink_missing_check(), bt_entry_unique_check(), bt_index_block_validate(), bt_index_check_callback(), bt_metap(), bt_multi_page_stats(), bt_normalize_tuple(), bt_page_items_bytea(), bt_page_items_internal(), bt_page_stats_internal(), bt_recheck_sibling_links(), bt_report_duplicate(), bt_target_page_check(), bt_tuple_present_callback(), BTreeTupleGetHeapTIDCareful(), btvalidate(), buffer_call_start_io(), buffer_call_terminate_io(), buffer_readv_report(), BufFileDumpBuffer(), BufFileLoadBuffer(), BufFileOpenFileSet(), BufFileReadCommon(), BufFileSeek(), BufFileSize(), BufFileTruncateFileSet(), build_attrmap_by_name(), build_column_default(), build_datatype(), build_server_first_message(), build_tuplestore_recursively(), BuildDescForRelation(), buildRelationAliases(), BuildRelationExtStatistics(), builtin_locale_encoding(), builtin_validate_locale(), BumpContextCreate(), bytea_int2(), bytea_int4(), bytea_int8(), bytea_overlay(), bytea_substring(), byteaGetBit(), byteaGetByte(), byteain(), byteaSetBit(), byteaSetByte(), calc_rank_cd(), calculate_frame_offsets(), calculate_relation_size(), calculate_tablespace_size(), call_bool_check_hook(), call_enum_check_hook(), call_int_check_hook(), call_pltcl_start_proc(), call_real_check_hook(), call_string_check_hook(), cannotCastJsonbValue(), cash_dist(), cash_div_cash(), cash_div_float8(), cash_div_int64(), cash_in(), cash_mi_cash(), cash_mul_float8(), cash_mul_int64(), cash_pl_cash(), CastCreate(), cfunc_resolve_polymorphic_argtypes(), changeDependenciesOn(), ChangeToDataDir(), char2wchar(), check_acl(), check_agg_arguments(), check_agg_arguments_walker(), check_and_init_gencol(), check_and_set_sync_info(), check_av_worker_gucs(), check_can_set_role(), check_circularity(), check_collation_set(), check_conn_params(), check_default_partition_contents(), check_default_table_access_method(), check_default_tablespace(), check_default_text_search_config(), check_duplicates_in_publist(), check_enable_rls(), check_encoding_locale_matches(), check_escape_warning(), check_exclusion_or_unique_constraint(), check_for_column_name_collision(), check_foreign_key(), check_ident_usermap(), check_index_is_clusterable(), check_index_page(), check_lateral_ref_ok(), check_locale(), check_nested_generated_walker(), check_new_partition_bound(), check_oauth_validator(), check_object_ownership(), check_of_type(), check_parameter_resolution_walker(), check_password(), check_primary_key(), check_publication_add_relation(), check_publication_add_schema(), check_publications(), check_publications_origin(), check_relation_block_range(), check_relation_privileges(), check_relation_relkind(), check_relation_updatable(), check_restricted_library_name(), check_role(), check_role_grantor(), check_role_membership_authorization(), check_rolespec_name(), check_safe_enum_use(), check_same_host_or_net(), check_session_authorization(), check_simple_rowfilter_expr_walker(), check_sql_fn_statement(), check_sql_stmt_retval(), check_srf_call_placement(), check_ssl_key_file_permissions(), check_stack_depth(), check_string_escape_warning(), check_temp_tablespaces(), check_transform_function(), check_unicode_value(), check_usermap(), check_valid_extension_name(), check_valid_version_name(), CheckAlterPublication(), CheckAlterSubOption(), CheckAlterTableIsSafe(), CheckAndGetDbnameFromConninfo(), CheckAttributeNamesTypes(), CheckAttributeType(), CheckBuiltinCryptoMode(), CheckCmdReplicaIdentity(), checkDataDir(), checkDomainOwner(), CheckDuplicateColumnOrPathNames(), checkEnumOwner(), checkExprIsVarFree(), CheckForSerializableConflictIn(), CheckForSerializableConflictOut(), CheckForSerializableConflictOutNeeded(), CheckForSessionAndXactLocks(), CheckForStandbyTrigger(), CheckFunctionValidatorAccess(), CheckIndexCompatible(), checkInsertTargets(), checkJsonOutputFormat(), CheckLogicalDecodingRequirements(), CheckMD5Auth(), checkMembershipInCurrentExtension(), CheckMyDatabase(), checkNameSpaceConflicts(), CheckPointLogicalRewriteHeap(), CheckPointReplicationOrigin(), CheckPointSnapBuild(), CheckPredicate(), CheckPubRelationColumnList(), CheckRADIUSAuth(), CheckRecoveryConflictDeadlock(), CheckRecoveryConsistency(), CheckRelationTableSpaceMove(), CheckRequiredParameterValues(), CheckRestrictedOperation(), checkRuleResultList(), CheckSASLAuth(), CheckSelectLocking(), CheckSetNamespace(), checkSharedDependencies(), CheckSlotPermissions(), CheckSlotRequirements(), checkStringLen(), CheckSubscriptionRelkind(), CheckTableNotInUse(), CheckTablespaceDirectory(), checkTargetlistEntrySQL92(), checkTimeLineSwitch(), checkTimezoneIsUsedForCast(), CheckTransactionBlock(), CheckValidResultRel(), CheckValidRowMarkRel(), CheckVarSlotCompatibility(), checkViewColumns(), checkWellFormedRecursion(), checkWellFormedRecursionWalker(), CheckXLogRemoved(), chr(), cidr_abbrev(), cidr_set_masklen(), circle_in(), circle_poly(), circle_recv(), cleanup_tsquery_stopwords(), clear_subscription_skip_lsn(), ClientAuthentication(), CloneFkReferencing(), ClosePipeFromProgram(), ClosePipeToProgram(), cluster(), cluster_is_permitted_for_relation(), cluster_rel(), coerce_record_to_complex(), coerce_to_boolean(), coerce_to_common_type(), coerce_to_specific_type_typmod(), coerceJsonFuncExpr(), CollationCreate(), collectMatchBitmap(), colNameToVar(), CommandCounterIncrement(), CommentObject(), commit_prepared_cb_wrapper(), compare_files(), comparetup_index_btree_tiebreak(), compatConnectbyTupleDescs(), compatCrosstabTupleDescs(), compatible_oper(), compile_plperl_function(), compile_pltcl_function(), compileTheLexeme(), compileTheSubstitute(), complex_in(), compute_common_attribute(), compute_function_attributes(), compute_return_type(), ComputeIndexAttrs(), ComputePartitionAttrs(), connect_pg_server(), connectby_text(), connectby_text_serial(), ConstraintSetParentConstraint(), construct_md_array(), ConversionCreate(), convert_and_check_filename(), convert_any_priv_string(), convert_column_name(), convert_function_name(), convert_type_name(), convertJsonbArray(), convertJsonbObject(), cookConstraint(), cookDefault(), copy_file(), copy_replication_slot(), copy_table(), copy_table_data(), copydir(), CopyFrom(), CopyFromBinaryOneRow(), CopyFromTextLikeOneRow(), CopyGetAttnums(), CopyGetData(), CopyReadAttributesCSV(), CopyReadAttributesText(), CopyReadBinaryAttribute(), CopyReadLineText(), CopySendEndOfRow(), count_nondeletable_pages(), count_usable_fds(), countVariablesFromJsonb(), create_ctas_nodata(), create_distinct_paths(), create_ordinary_grouping_paths(), create_pg_locale(), create_pg_locale_icu(), create_tablespace_directories(), CreateAccessMethod(), CreateAnonymousSegment(), CreateCast(), CreateCheckPoint(), CreateConversionCommand(), createdb(), CreateDecodingContext(), CreateDirAndVersionFile(), CreateEventTrigger(), CreateExtension(), CreateExtensionInternal(), CreateForeignDataWrapper(), CreateForeignServer(), CreateFunction(), CreateInheritance(), CreateInitDecodingContext(), CreateLockFile(), createNewConnection(), CreateOpFamily(), CreateOptsFile(), CreatePolicy(), CreatePortal(), CreatePredicateLock(), CreateProceduralLanguage(), CreatePublication(), CreateReplicationSlot(), CreateRestartPoint(), CreateRole(), CreateSchemaCommand(), CreateSlotOnDisk(), CreateStatistics(), CreateSubscription(), CreateTableAsRelExists(), CreateTableSpace(), CreateTransform(), CreateTriggerFiringOn(), CreateUserMapping(), crosstab(), crosstab_hash(), cube_a_f8(), cube_a_f8_f8(), cube_c_f8(), cube_c_f8_f8(), cube_coord(), cube_coord_llur(), cube_recv(), cube_subset(), cube_yyerror(), currtid_for_view(), currtid_internal(), currval_oid(), cursor_to_xml(), cursor_to_xmlschema(), dacos(), dacosd(), dacosh(), dasin(), dasind(), datanh(), date2timestamp_opt_overflow(), date2timestamptz_opt_overflow(), date_in(), date_mi(), date_mii(), date_pli(), date_recv(), daterange_canonical(), datetime_timestamp(), DateTimeParseError(), datetimetz_timestamptz(), datum_to_json_internal(), datum_to_jsonb_internal(), datumGetSize(), db_dir_size(), db_encoding_convert(), dbase_redo(), dblink_build_sql_delete(), dblink_build_sql_insert(), dblink_build_sql_update(), dblink_conn_not_avail(), dblink_connect(), dblink_connstr_check(), dblink_exec(), dblink_fdw_validator(), dblink_fetch(), dblink_get_conn(), dblink_res_error(), dblink_security_check(), DCH_from_char(), DCH_to_char(), dcos(), dcosd(), dcot(), dcotd(), dead_items_alloc(), DeadLockReport(), DebugFileOpen(), DecodeTimezoneName(), deconstruct_array(), DeconstructQualifiedName(), defGetBoolean(), defGetCopyHeaderChoice(), defGetCopyLogVerbosityChoice(), defGetCopyOnErrorChoice(), defGetCopyRejectLimitOption(), defGetGeneratedColsOption(), defGetInt32(), defGetInt64(), defGetNumeric(), defGetObjectId(), defGetQualifiedName(), defGetStreamingMode(), defGetString(), defGetStringList(), defGetTypeLength(), defGetTypeName(), define_custom_variable(), DefineAggregate(), DefineCollation(), DefineCompositeType(), DefineDomain(), DefineEnum(), DefineIndex(), DefineOpClass(), DefineOperator(), DefineOpFamily(), DefineQueryRewrite(), DefineRange(), DefineRelation(), DefineSavepoint(), DefineSequence(), DefineTSConfiguration(), DefineTSDictionary(), DefineTSParser(), DefineTSTemplate(), DefineType(), DefineView(), DefineVirtualRelation(), DeleteAllExportedSnapshotFiles(), deleteConnection(), DeleteInheritsTuple(), DelRoleMems(), deserialize_deflist(), destroy_tablespace_directories(), DetermineTimeZoneAbbrevOffsetTS(), dintdict_init(), DisableSubscriptionAndExit(), disconnect_cached_connections(), dispell_init(), div_var(), div_var_int(), dlog1(), dlog10(), do_analyze_rel(), do_autovacuum(), do_connect(), do_pg_abort_backup(), do_pg_backup_start(), do_pg_backup_stop(), do_setval(), do_to_timestamp(), do_truncate(), DoCopy(), does_not_exist_skipping(), domain_check_input(), domain_state_setup(), domainAddCheckConstraint(), domainAddNotNullConstraint(), DoPortalRewind(), dpow(), drop_local_obsolete_slots(), DropConfigurationMapping(), dropconstraint_internal(), DropDatabase(), dropdb(), DropErrorMsgNonExistent(), DropErrorMsgWrongType(), dropOperators(), DropOwnedObjects(), dropProcedures(), DropRole(), DropSubscription(), DropTableSpace(), dsa_allocate_extended(), dsa_attach(), dshash_create(), dsimple_init(), dsin(), dsind(), dsm_backend_startup(), dsm_cleanup_for_mmap(), dsm_create(), dsm_impl_mmap(), dsm_impl_pin_segment(), dsm_impl_posix(), dsm_impl_sysv(), dsm_impl_unpin_segment(), dsm_postmaster_shutdown(), dsnowball_init(), dsqrt(), dsynonym_init(), dtan(), dtand(), dtoi2(), dtoi4(), dtoi8(), dummy_object_relabel(), dumptuples(), durable_rename(), durable_unlink(), dxsyn_init(), EA_get_flat_size(), each_array_start(), each_scalar(), each_worker_jsonb(), ean2isn(), ean2string(), ECPGconnect(), elements_object_start(), elements_scalar(), elements_worker_jsonb(), emit_audit_message(), EnableDisableRule(), EnableDisableTrigger(), EnableLockPagesPrivilege(), encrypt_password(), EndCopy(), EndCopyFrom(), EndPrepare(), EndTransactionBlock(), enforce_generic_type_consistency(), enlargeStringInfo(), entry_reset(), enum_cmp_internal(), enum_first(), enum_in(), enum_last(), enum_out(), enum_range_all(), enum_range_bounds(), enum_recv(), enum_send(), EnumValuesCreate(), error_commit_ts_disabled(), error_duplicate_filter_variable(), error_multiple_recovery_targets(), error_view_not_updatable(), errorConflictingDefElem(), errorMissingColumn(), errorMissingRTE(), esc_dec_len(), esc_decode(), EvalPlanQualFetchRowMark(), EvaluateParams(), exec_assign_value(), exec_bind_message(), exec_check_assignable(), exec_describe_portal_message(), exec_describe_statement_message(), exec_dynquery_with_params(), exec_eval_datum(), exec_eval_expr(), exec_execute_message(), exec_init_tuple_store(), exec_move_row_from_fields(), exec_object_restorecon(), exec_parse_message(), exec_replication_command(), exec_run_select(), exec_simple_query(), exec_stmt_assert(), exec_stmt_case(), exec_stmt_close(), exec_stmt_dynexecute(), exec_stmt_execsql(), exec_stmt_fetch(), exec_stmt_forc(), exec_stmt_foreach_a(), exec_stmt_fori(), exec_stmt_getdiag(), exec_stmt_open(), exec_stmt_raise(), exec_stmt_return(), exec_stmt_return_next(), exec_stmt_return_query(), ExecAlterDefaultPrivilegesStmt(), ExecAlterExtensionContentsRecurse(), ExecAlterExtensionContentsStmt(), ExecAlterExtensionStmt(), ExecBRInsertTriggers(), ExecBSDeleteTriggers(), ExecBSInsertTriggers(), ExecBSTruncateTriggers(), ExecBSUpdateTriggers(), ExecBuildUpdateProjection(), ExecCallTriggerFunc(), ExecCheckIndexConstraints(), ExecCheckPlanOutput(), ExecCheckTupleVisible(), ExecConstraints(), ExecCrossPartitionUpdate(), ExecCrossPartitionUpdateForeignKey(), execCurrentOf(), ExecCustomMarkPos(), ExecCustomRestrPos(), ExecDelete(), ExecEvalArrayExpr(), ExecEvalConstraintCheck(), ExecEvalConstraintNotNull(), ExecEvalCurrentOfExpr(), ExecEvalFieldSelect(), ExecEvalJsonCoercionFinish(), ExecEvalJsonExprPath(), ExecEvalParamExtern(), ExecEvalWholeRowVar(), ExecFindPartition(), ExecGrant_Language_check(), ExecGrant_Relation(), ExecGrant_Type_check(), ExecHashJoinNewBatch(), ExecInitAgg(), ExecInitExprRec(), ExecInitFunc(), ExecInitMergeJoin(), ExecInitSubscriptingRef(), ExecLockRows(), ExecMakeFunctionResultSet(), ExecMakeTableFunctionResult(), ExecMergeMatched(), ExecOnConflictUpdate(), ExecOpenScanRelation(), ExecPartitionCheckEmitError(), ExecPrepareTuplestoreResult(), ExecReindex(), ExecScanSubPlan(), ExecSecLabelStmt(), ExecSetParamPlan(), ExecSetVariableStmt(), ExecUpdate(), execute_extension_script(), execute_sql_string(), executeBinaryArithmExpr(), executeDateTimeMethod(), ExecuteDoStmt(), ExecuteGrantStmt(), executeItemOptUnwrapTarget(), executeKeyValueMethod(), executeNumericItemMethod(), ExecuteQuery(), ExecuteRecoveryCommand(), ExecuteTruncate(), ExecuteTruncateGuts(), executeUnaryArithmExpr(), ExecVacuum(), ExecWithCheckOptions(), ExecWithoutOverlapsNotEmpty(), existsTimeLineHistory(), ExitPostmaster(), exp_var(), expand_col_privileges(), expand_vacuum_rel(), ExpandAllTables(), ExpandColumnRefStar(), expandTableLikeClause(), explain_ExecutorEnd(), ExportSnapshot(), exprType(), ExtendBufferedRelLocal(), ExtendBufferedRelShared(), extract_date(), extract_variadic_args(), ExtractExtensionList(), extractModify(), FastPathGetRelationLockEntry(), fatal_llvm_error_handler(), fatal_llvm_new_handler(), fatal_system_new_handler(), fetch_array_arg_replace_nulls(), fetch_cursor_param_value(), fetch_finfo_record(), fetch_fp_info(), fetch_remote_table_info(), fetch_table_list(), FetchPreparedStatement(), file_acquire_sample_rows(), file_fdw_validator(), fileAnalyzeForeignTable(), FileClose(), fileIterateForeignScan(), FileWriteV(), finalize_grouping_exprs_walker(), find_composite_type_dependencies(), find_expr_references_walker(), find_in_path(), find_option(), find_provider(), find_typed_table_dependencies(), findDependentObjects(), FindFKPeriodOpers(), findRangeCanonicalFunction(), findRangeSubOpclass(), findRangeSubtypeDiffFunction(), findTargetlistEntrySQL92(), findTypeAnalyzeFunction(), findTypeInputFunction(), findTypeOutputFunction(), findTypeReceiveFunction(), findTypeSendFunction(), findTypeSubscriptingFunction(), findTypeTypmodinFunction(), findTypeTypmodoutFunction(), finish_nodeitem(), finish_sync_worker(), finite_interval_mi(), finite_interval_pl(), fireRIRrules(), fixed_paramref_hook(), flatten_set_variable_args(), flattenJsonPathParseItem(), float4in_internal(), float8_timestamptz(), float8in_internal(), float_overflow_error(), float_underflow_error(), float_zero_divide_error(), FloatExceptionHandler(), fmgr_info_cxt_security(), fmgr_internal_validator(), fmgr_sql(), fmgr_sql_validator(), forbidden_in_wal_sender(), forkname_to_number(), free_parsestate(), from_char_parse_int_len(), from_char_seq_search(), from_char_set_int(), from_char_set_mode(), fsm_page_contents(), fsync_fname_ext(), ftoi2(), ftoi4(), ftoi8(), g_cube_distance(), g_int_compress(), g_int_decompress(), gbtreekey_in(), gbtreekey_out(), gc_qtexts(), gen_random_uuid(), generate_error_response(), generate_nonunion_paths(), generate_recursion_path(), generate_series_step_int4(), generate_series_step_int8(), generate_series_step_numeric(), generate_series_timestamp(), generate_series_timestamptz_internal(), generate_uuidv7(), generateClonedIndexStmt(), generateSerialExtraStmts(), GenerationContextCreate(), Generic_Text_IC_like(), GenericMatchText(), get_am_type_oid(), get_arg_by_name(), get_attr_stat_type(), get_base_conninfo(), get_cached_rowtype(), get_cast_oid(), get_collation_actual_version_builtin(), get_collation_actual_version_libc(), get_collation_oid(), get_connect_string(), get_controlfile_by_exact_path(), get_conversion_oid(), get_crosstab_tuplestore(), get_database_oid(), get_dirent_type(), get_domain_constraint_oid(), get_event_trigger_oid(), get_expr_result_tupdesc(), get_extension_oid(), get_fn_opclass_options(), get_foreign_data_wrapper_oid(), get_foreign_server_oid(), get_func_expr(), get_language_oid(), get_multirange_io_data(), get_namespace_oid(), get_object_address(), get_object_address_attrdef(), get_object_address_attribute(), get_object_address_defacl(), get_object_address_opf_member(), get_object_address_publication_rel(), get_object_address_publication_schema(), get_object_address_relobject(), get_object_address_type(), get_object_address_usermapping(), get_page_from_raw(), get_publication_oid(), get_range_io_data(), get_raw_page(), get_raw_page_1_9(), get_raw_page_fork_1_9(), get_raw_page_internal(), get_record_type_from_argument(), get_record_type_from_query(), get_relation_by_qualified_name(), get_relation_constraint_attnos(), get_relation_constraint_oid(), get_relation_info(), get_relation_policy_oid(), get_required_extension(), get_rewrite_oid(), get_role_oid(), get_rolespec_oid(), get_rolespec_tuple(), get_rte_attribute_is_dropped(), get_sort_group_operators(), get_sql_insert(), get_sql_update(), get_statistics_object_oid(), get_subscription_oid(), get_tablespace_oid(), get_th(), get_transform_oid(), get_trigger_oid(), get_ts_config_oid(), get_ts_dict_oid(), get_ts_parser_func(), get_ts_parser_oid(), get_ts_template_func(), get_ts_template_oid(), get_tsearch_config_filename(), get_tuple_of_interest(), get_windowfunc_expr_helper(), getAffixFlagSet(), getAnotherTuple(), getArrayIndex(), GetAttributeCompression(), GetAttributeStorage(), GetColumnDefCollation(), GetConfFilesInDir(), GetConfigOption(), GetConfigOptionByName(), GetConfigOptionResetString(), GetConflictingVirtualXIDs(), GetCurrentCommandId(), GetCurrentTimeUsec(), getdatafield(), GetDefaultOpClass(), GetDefaultTablespace(), GetExtensibleNodeEntry(), GetFdwRoutine(), GetFdwRoutineByServerId(), getid(), GetIndexAmRoutineByAmId(), getInstallationPaths(), getJsonPathVariable(), GetLocalVictimBuffer(), GetMultiXactIdMembers(), GetNamedDSMSegment(), GetNewMultiXactId(), GetNewOidWithIndex(), GetNewTransactionId(), getNextFlagFromString(), GetOperatorFromCompareType(), getParamDescriptions(), getRowDescriptions(), GetRunningTransactionData(), GetSerializableTransactionSnapshot(), GetSerializableTransactionSnapshotInt(), GetSnapshotData(), gettoken_query(), gettoken_query_standard(), gettoken_tsvector(), getTokenTypes(), GetTupleForTrigger(), getTypeBinaryInputInfo(), getTypeBinaryOutputInfo(), getTypeInputInfo(), getTypeOutputInfo(), GetUserMapping(), GetUserNameFromId(), getWeights(), ghstore_in(), ghstore_out(), gin_check_parent_keys_consistency(), gin_check_posting_tree_parent_keys_consistency(), gin_clean_pending_list(), gin_leafpage_items(), gin_metapage_info(), gin_page_opaque_info(), ginadjustmembers(), GinBufferInit(), ginCombineData(), GinFormTuple(), ginvalidate(), gist_page_items(), gist_page_items_bytea(), gist_page_opaque_info(), gistadjustmembers(), gistcheckpage(), gistdoinsert(), gistfixsplit(), gistSplit(), gistUserPicksplit(), gistvacuumpage(), gistvalidate(), GrantRole(), grouping_planner(), gtrgm_in(), gtrgm_out(), gtsvectorin(), guc_malloc(), guc_realloc(), handle_oauth_sasl_error(), HandleChildCrash(), HandleConcurrentAbort(), HandleFunctionRequest(), HandleUploadManifestPacket(), has_sequence_privilege_id(), has_sequence_privilege_id_id(), has_sequence_privilege_id_name(), has_sequence_privilege_name(), has_sequence_privilege_name_id(), has_sequence_privilege_name_name(), hash_array(), hash_array_extended(), hash_array_start(), hash_bitmap_info(), hash_create(), hash_metapage_info(), hash_multirange(), hash_multirange_extended(), hash_page_items(), hash_page_stats(), hash_page_type(), hash_range(), hash_range_extended(), hash_record(), hash_record_extended(), hash_scalar(), hash_search_with_hash_value(), hashbpchar(), hashbpcharextended(), hashtext(), hashtextextended(), hashvalidate(), heap_acquire_tuplock(), heap_create(), heap_create_with_catalog(), heap_delete(), heap_force_common(), heap_form_minimal_tuple(), heap_form_tuple(), heap_inplace_lock(), heap_lock_tuple(), heap_page_items(), heap_prepare_insert(), heap_truncate_check_FKs(), heap_tuple_infomask_flags(), heap_update(), heap_vacuum_rel(), heap_xlog_logical_rewrite(), heapam_tuple_lock(), hex_decode_safe(), hlparsetext(), HoldPinnedPortals(), hstore_from_array(), hstore_from_arrays(), hstore_populate_record(), hstore_recv(), hstore_subscript_assign(), hstore_subscript_transform(), hstore_to_plpython(), hstoreArrayToPairs(), hstoreCheckKeyLen(), hstoreCheckKeyLength(), hstoreCheckValLen(), hstoreCheckValLength(), i4tochar(), i4toi2(), i8tooid(), icu_language_tag(), icu_validate_locale(), ident_inet(), identify_update_path(), ImportForeignSchema(), ImportSnapshot(), in_range_float4_float8(), in_range_float8_float8(), in_range_int2_int4(), in_range_int4_int4(), in_range_int4_int8(), in_range_int8_int8(), in_range_interval_interval(), in_range_numeric_numeric(), in_range_time_interval(), in_range_timestamp_interval(), in_range_timestamptz_interval(), in_range_timetz_interval(), incompatible_module_error(), index_check_primary_key(), index_checkable(), index_concurrently_create_copy(), index_constraint_create(), index_create(), index_drop(), index_form_tuple_context(), index_opclass_options(), IndexOnlyNext(), inet_abbrev(), inet_merge(), inet_set_masklen(), inetand(), inetmi(), inetor(), infer_arbiter_indexes(), init_execution_state(), init_MultiFuncCall(), init_params(), init_sexpr(), initArrayResultArr(), InitControlFile(), InitFileAccess(), initGinState(), initialize_dh(), initialize_ecdh(), initialize_peragg(), InitializeClientEncoding(), InitializeLogRepWorker(), InitializeMaxBackends(), InitializeSessionUserId(), InitLocalBuffers(), InitMaterializedSRF(), InitPgFdwOptions(), InitPostgres(), InitProcess(), InitTempTableNamespace(), initTrie(), InitWalRecovery(), InitXLogReaderState(), inner_subltree(), insert_username(), InsertRule(), instantiate_empty_record_variable(), int24div(), int24mi(), int24mul(), int24pl(), int28div(), int28mi(), int28mul(), int28pl(), int2_dist(), int2abs(), int2div(), int2mi(), int2mod(), int2mul(), int2pl(), int2um(), int2vectorin(), int2vectorrecv(), int42div(), int42mi(), int42mul(), int42pl(), int48div(), int48mi(), int48mul(), int48pl(), int4_dist(), int4abs(), int4div(), int4gcd_internal(), int4inc(), int4lcm(), int4mi(), int4mod(), int4mul(), int4pl(), int4random(), int4range_canonical(), int4um(), int82(), int82div(), int82mi(), int82mul(), int82pl(), int84(), int84div(), int84mi(), int84mul(), int84pl(), int8_dist(), int8abs(), int8dec(), int8div(), int8gcd_internal(), int8inc(), int8lcm(), int8mi(), int8mod(), int8mul(), int8pl(), int8random(), int8range_canonical(), int8um(), internal_flush_buffer(), internal_get_result_type(), internal_inetpl(), internal_load_library(), InternalIpcMemoryCreate(), InternalIpcSemaphoreCreate(), interpret_AS_clause(), interpret_func_parallel(), interpret_func_support(), interpret_function_parameter_list(), interval_avg(), interval_div(), interval_in(), interval_justify_days(), interval_justify_hours(), interval_justify_interval(), interval_mi(), interval_mul(), interval_part_common(), interval_pl(), interval_sum(), interval_time(), interval_trunc(), interval_um_internal(), intervaltypmodin(), intorel_startup(), inv_open(), inv_read(), inv_seek(), inv_truncate(), inv_write(), iso8859_to_utf8(), issue_xlog_fsync(), IsThereCollationInNamespace(), IsThereFunctionInNamespace(), IsThereOpClassInNamespace(), IsThereOpFamilyInNamespace(), json_agg_transfn_worker(), json_build_object_worker(), json_errsave_error(), json_object(), json_object_agg_transfn_worker(), json_object_two_arg(), json_validate(), jsonb_agg_transfn_worker(), jsonb_array_length(), jsonb_build_object_worker(), jsonb_delete(), jsonb_delete_array(), jsonb_delete_idx(), jsonb_delete_path(), jsonb_insert(), jsonb_object(), jsonb_object_agg_transfn_worker(), jsonb_object_keys(), jsonb_object_two_arg(), jsonb_path_match_internal(), jsonb_set(), jsonb_set_lax(), jsonb_subscript_check_subscripts(), jsonb_subscript_transform(), JsonEncodeDateTime(), JsonItemFromDatum(), jsonpath_yyerror(), jsonPathFromCstring(), JsonPathQuery(), JsonPathValue(), JsValueToJsObject(), KeepFileRestoredFromArchive(), LargeObjectDrop(), lastval(), lazy_check_wraparound_failsafe(), lazy_scan_heap(), lazy_truncate_heap(), lazy_vacuum_heap_rel(), length_in_encoding(), libpqrcv_alter_slot(), libpqrcv_check_conninfo(), libpqrcv_connect(), libpqrcv_create_slot(), libpqrcv_endstreaming(), libpqrcv_exec(), libpqrcv_get_conninfo(), libpqrcv_get_dbname_from_conninfo(), libpqrcv_identify_system(), libpqrcv_processTuples(), libpqrcv_readtimelinehistoryfile(), libpqrcv_receive(), libpqrcv_send(), libpqrcv_startstreaming(), libpqsrv_connect_prepare(), like_fixed_prefix(), line_construct_pp(), line_decode(), line_in(), line_recv(), ListenServerPort(), ln_var(), lo_get_fragment_internal(), lo_import_internal(), lo_read(), lo_truncate_internal(), lo_write(), load_categories_hash(), load_dh_file(), load_enum_cache_data(), load_external_function(), load_hba(), load_libraries(), load_validator_library(), LoadArchiveLibrary(), LoadPublications(), LocalToUtf(), locate_stem_module(), lock_twophase_recover(), LockAcquireExtended(), LockGXact(), LockSchemaList(), LockTableRecurse(), LockViewRecurse_walker(), log_disconnections(), LogCheckpointEnd(), LogCheckpointStart(), LogChildExit(), logfile_open(), logfile_rotate_dest(), logical_end_heap_rewrite(), logical_heap_rewrite_flush_mappings(), logical_rewrite_log_mapping(), LogicalParallelApplyLoop(), logicalrep_rel_mark_updatable(), logicalrep_rel_open(), logicalrep_worker_attach(), logicalrep_worker_launch(), LogicalRepApplyLoop(), LogicalRepSyncTableStart(), LogRecoveryConflict(), lookup_agg_function(), lookup_am_handler_func(), lookup_fdw_handler_func(), lookup_rowtype_tupdesc_domain(), lookup_rowtype_tupdesc_internal(), lookup_type_cache(), LookupFuncName(), LookupFuncWithArgs(), LookupOperName(), LookupTypeNameExtended(), LookupTypeNameOid(), lpad(), lt_q_regex(), ltree_concat(), ltree_gist_in(), ltree_gist_out(), ltree_gist_relopts_validator(), ltree_to_plpython(), ltsReadBlock(), ltsWriteBlock(), ltxtq_out(), ltxtq_send(), macaddr8_in(), macaddr8tomacaddr(), macaddr_in(), main(), make_absolute_path(), make_callstmt_target(), make_date(), make_distinct_op(), make_expanded_record_from_tupdesc(), make_expanded_record_from_typeid(), make_inh_translation_list(), make_interval(), make_libc_collator(), make_modifytable(), make_op(), make_outerjoininfo(), make_pathkeys_for_window(), make_result_opt_error(), make_row_comparison_op(), make_row_distinct_op(), make_ruledef(), make_scalar_array_op(), make_time(), make_timestamp_internal(), make_timestamptz_at_timezone(), make_tsvector(), makeMultirangeTypeName(), makepol(), makeRangeVarFromNameList(), makeWholeRowVar(), map_sql_value_to_xml_value(), mark_index_clustered(), MarkAsPreparing(), MarkGUCPrefixReserved(), MarkInheritDetached(), MarkPortalActive(), matchLocks(), MatchText(), materializeResult(), maybe_reread_subscription(), maybe_start_skipping_changes(), md5_bytea(), md5_text(), md_readv_report(), mdcreate(), mdextend(), mdimmedsync(), mdopenfork(), mdreadv(), mdstartreadv(), mdtruncate(), mdunlinkfork(), mdwritev(), mdzeroextend(), MemoryContextAllocationFailure(), merge_acl_with_grant(), merge_collation_state(), merge_publications(), MergeAttributes(), MergeAttributesIntoExisting(), MergeCheckConstraint(), MergeChildAttribute(), MergeConstraintsIntoExisting(), MergeInheritedAttribute(), MergeWithExistingConstraint(), metaphone(), moddatetime(), movedb(), mul_size(), multirange_constructor2(), multirange_in(), namerecv(), NamespaceCreate(), network_host(), network_in(), network_out(), network_recv(), network_show(), NextCopyFromRawFieldsInternal(), nextval_internal(), NIAddAffix(), NIImportAffixes(), NIImportDictionary(), NIImportOOAffixes(), NISortDictionary(), NonFiniteIntervalPart(), NonFiniteTimestampTzPart(), normal_rand(), NUM_processor(), NUMDesc_prepare(), numeric_div_opt_error(), numeric_div_trunc(), numeric_fac(), numeric_in(), numeric_int2(), numeric_int4_opt_error(), numeric_int8_opt_error(), numeric_ln(), numeric_log(), numeric_mod_opt_error(), numeric_pg_lsn(), numeric_power(), numeric_recv(), numeric_sqrt(), numerictypmodin(), numericvar_to_double_no_overflow(), oauth_exchange(), oauth_init(), ObjectsInPublicationToOids(), oidvectorrecv(), okeys_array_start(), okeys_scalar(), OnConflict_CheckForSerializationFailure(), op_error(), OpClassCacheLookup(), open_auth_file(), OpenPipeStream(), OpenTableList(), OpenTransientFilePerm(), OpenWalSummaryFile(), OperatorCreate(), OperatorShellMake(), OperatorUpd(), OperatorValidateParams(), OpFamilyCacheLookup(), pa_send_data(), pa_switch_to_partial_serialize(), pa_wait_for_xact_finish(), page_checksum_internal(), page_header(), PageAddItemExtended(), PageGetItemIdCareful(), PageIndexMultiDelete(), PageIndexTupleDelete(), PageIndexTupleDeleteNoCompact(), PageIndexTupleOverwrite(), PageIsVerified(), PageRepairFragmentation(), pair_decode(), palloc_btree_page(), parallel_vacuum_process_all_indexes(), ParallelApplyWorkerMain(), ParallelWorkerMain(), ParameterAclLookup(), parse_affentry(), parse_and_validate_value(), parse_basebackup_options(), parse_datetime(), parse_extension_control_file(), parse_fcall_arguments(), parse_format(), parse_hba_auth_opt(), parse_hba_line(), parse_ident(), parse_jsonb_index_flags(), parse_key_value_arrays(), parse_kvpairs_for_auth(), parse_lquery(), parse_ltree(), parse_one_reloption(), parse_output_parameters(), parse_phrase_operator(), parse_publication_options(), parse_re_flags(), parse_sane_timezone(), parse_snapshot(), parse_snapshot_filename(), parse_subscription_options(), parse_test_flags(), parse_tsquery(), parseCheckAggregates(), ParseConfigFile(), ParseConfigFp(), parseCreateReplSlotOptions(), ParseExplainOptionList(), ParseFuncOrColumn(), parseIntFromText(), parseNameAndArgTypes(), parseRelOptionsInternal(), parserOpenTable(), parsetext(), parseTypeString(), parseUnicode(), parseVxidFromText(), parseXidFromText(), partitioned_table_reloptions(), path_add(), path_decode(), path_in(), path_poly(), path_recv(), PathNameCreateTemporaryDir(), PathNameCreateTemporaryFile(), PathNameDeleteTemporaryFile(), PathNameOpenFilePerm(), PathNameOpenTemporaryFile(), percentile_cont_final_common(), percentile_disc_final(), perform_base_backup(), perform_default_encoding_conversion(), PerformAuthentication(), PerformCursorOpen(), PerformPortalClose(), PerformPortalFetch(), PerformRadiusTransaction(), PerformWalRecovery(), pg_analyze_and_rewrite_varparams(), pg_any_to_server(), pg_attribute_aclcheck_all_ext(), pg_attribute_aclmask_ext(), pg_backup_start(), pg_backup_stop(), pg_base64_decode(), pg_be_scram_build_secret(), pg_buffercache_evict(), pg_cancel_backend(), pg_class_aclmask_ext(), pg_clear_attribute_stats(), pg_collation_actual_version(), pg_collation_for(), pg_control_checkpoint(), pg_control_init(), pg_control_recovery(), pg_control_system(), pg_convert(), pg_create_restore_point(), pg_crypt(), pg_cryptohash_create(), pg_current_logfile(), pg_current_wal_flush_lsn(), pg_current_wal_insert_lsn(), pg_current_wal_lsn(), pg_database_collation_actual_version(), pg_database_size_oid(), pg_decode_startup(), pg_decrypt(), pg_decrypt_iv(), pg_dependencies_in(), pg_dependencies_recv(), pg_do_encoding_conversion(), pg_encrypt(), pg_encrypt_iv(), pg_event_trigger_ddl_commands(), pg_event_trigger_dropped_objects(), pg_event_trigger_table_rewrite_oid(), pg_event_trigger_table_rewrite_reason(), pg_extension_config_dump(), pg_file_exists(), pg_flush_data(), pg_freespace(), pg_gen_salt(), pg_gen_salt_rounds(), pg_get_encoding_from_locale(), pg_get_expr_worker(), pg_get_functiondef(), pg_get_multixact_members(), pg_get_object_address(), pg_get_serial_sequence(), pg_get_wal_record_info(), pg_get_wal_records_info_till_end_of_wal(), pg_get_wal_replay_pause_state(), pg_get_wal_stats_till_end_of_wal(), pg_GSS_error(), pg_hmac_create(), pg_import_system_collations(), pg_is_wal_replay_paused(), pg_largeobject_aclmask_snapshot(), pg_log_backend_memory_contexts(), pg_log_standby_snapshot(), pg_logical_slot_get_changes_guts(), pg_ls_dir_files(), pg_ls_replslotdir(), pg_ls_tmpdir(), pg_lsn_in(), pg_lsn_mii(), pg_lsn_pli(), pg_mcv_list_in(), pg_mcv_list_recv(), pg_namespace_aclmask_ext(), pg_ndistinct_in(), pg_ndistinct_recv(), pg_nextoid(), pg_parameter_acl_aclmask(), pg_prewarm(), pg_promote(), pg_random_bytes(), pg_read_binary_file_common(), pg_read_file_common(), pg_reload_conf(), pg_relpages(), pg_relpages_impl(), pg_relpagesbyid(), pg_replication_origin_create(), pg_replication_origin_session_progress(), pg_replication_origin_xact_setup(), pg_replication_slot_advance(), pg_rotate_logfile(), pg_sequence_parameters(), pg_set_regex_collation(), pg_signal_backend(), pg_size_bytes(), pg_snapshot_recv(), pg_split_walfile_name(), pg_stat_file(), pg_stat_get_progress_info(), pg_stat_reset_shared(), pg_stat_reset_subscription_stats(), pg_stat_statements_info(), pg_stat_statements_internal(), pg_stats_ext_mcvlist_items(), pg_stop_making_pinned_objects(), pg_strtoint16_safe(), pg_strtoint32_safe(), pg_strtoint64_safe(), pg_switch_wal(), pg_sync_replication_slots(), pg_tablespace_databases(), pg_tablespace_location(), pg_tablespace_size_oid(), pg_terminate_backend(), pg_to_ascii(), pg_type_aclmask_ext(), pg_tzenumerate_next(), pg_tzenumerate_start(), pg_unicode_to_server(), pg_visibility(), pg_visibility_map(), pg_wait_until_termination(), pg_wal_replay_pause(), pg_wal_replay_resume(), pg_wal_summary_contents(), pg_walfile_name(), pg_walfile_name_offset(), pgarch_archiveDone(), pgarch_ArchiverCopyLoop(), pgarch_readyXlog(), pgfdw_cancel_query_begin(), pgfdw_cancel_query_end(), pgfdw_exec_cleanup_query_end(), pgfdw_reject_incomplete_xact_state_change(), pgfdw_report_error(), pgfdw_security_check(), pgfdw_xact_callback(), PGLC_localeconv(), pgoutput_column_list_init(), pgoutput_startup(), PGReserveSemaphores(), pgrowlocks(), PGSemaphoreCreate(), PGSemaphoreLock(), PGSemaphoreTryLock(), PGSemaphoreUnlock(), PGSharedMemoryCreate(), pgss_shmem_shutdown(), pgss_shmem_startup(), pgstat_create_transactional(), pgstat_discard_stats(), pgstat_get_kind_from_str(), pgstat_heap(), pgstat_init_function_usage(), pgstat_read_statsfile(), pgstat_register_kind(), pgstat_relation(), pgstat_reset_replslot(), pgstat_write_statsfile(), pgstatginindex(), pgstatginindex_internal(), pgstathashindex(), pgstatindex(), pgstatindex_impl(), pgstatindexbyid(), pgstattuple(), pgstattuple_approx(), pgstattuple_approx_internal(), pgstattuplebyid(), pgwin32_create_signal_listener(), placeChar(), plan_recursive_revoke(), plperl_array_to_datum(), plperl_build_tuple_result(), plperl_call_perl_event_trigger_func(), plperl_call_perl_func(), plperl_call_perl_trigger_func(), plperl_create_sub(), plperl_func_handler(), plperl_init_interp(), plperl_modify_tuple(), plperl_return_next_internal(), plperl_spi_execute_fetch_result(), plperl_sv_to_datum(), plperl_sv_to_literal(), plperl_to_hstore(), plperl_trigger_handler(), plperl_trusted_init(), plperl_untrusted_init(), plperl_validator(), plpgsql_build_datatype_arrayof(), plpgsql_build_variable(), plpgsql_compile_callback(), plpgsql_exec_event_trigger(), plpgsql_exec_function(), plpgsql_exec_get_datum_type(), plpgsql_exec_get_datum_type_info(), plpgsql_exec_trigger(), plpgsql_param_eval_generic(), plpgsql_param_eval_generic_ro(), plpgsql_param_eval_recfield(), plpgsql_parse_cwordrowtype(), plpgsql_parse_cwordtype(), plpgsql_parse_err_condition(), plpgsql_parse_wordrowtype(), plpgsql_parse_wordtype(), plpgsql_post_column_ref(), plpgsql_recognize_err_condition(), plpgsql_validator(), plpgsql_yyerror(), plpython_to_hstore(), plsample_func_handler(), plsample_trigger_handler(), pltcl_build_tuple_result(), pltcl_elog(), pltcl_func_handler(), pltcl_trigger_handler(), PLy_abort_open_subtransactions(), PLy_cursor_fetch(), PLy_exec_function(), PLy_exec_trigger(), PLy_initialize(), PLy_modify_tuple(), PLy_procedure_create(), PLy_spi_execute_fetch_result(), PLy_spi_prepare(), PLyGenericObject_ToComposite(), PLyMapping_ToComposite(), PLyNumber_ToJsonbValue(), PLyObject_AsString(), PLyObject_ToJsonbValue(), PLySequence_ToArray(), PLySequence_ToArray_recurse(), PLySequence_ToComposite(), PLyUnicode_ToComposite(), policy_role_list_to_array(), poly_in(), poly_recv(), populate_array_check_dimension(), populate_array_report_expected_array(), populate_joinrel_with_paths(), populate_recordset_array_element_start(), populate_recordset_object_start(), populate_recordset_scalar(), populate_recordset_worker(), PortalDrop(), PortalRunSelect(), PortalSetResultFormat(), postgres_fdw_validator(), postgresAcquireSampleRowsFunc(), postgresBeginForeignInsert(), postgresExecForeignTruncate(), postgresImportForeignSchema(), PostgresMain(), postgresql_fdw_validator(), PostgresSingleUserMain(), PostmasterMain(), PostmasterStateMachine(), PostPrepare_Locks(), power_var(), power_var_int(), pq_copymsgbytes(), pq_getbyte_if_available(), pq_getkeepalivescount(), pq_getkeepalivesidle(), pq_getkeepalivesinterval(), pq_getmessage(), pq_getmsgbyte(), pq_getmsgbytes(), pq_getmsgend(), pq_getmsgrawstring(), pq_getmsgstring(), pq_getmsgtext(), pq_gettcpusertimeout(), pq_init(), pq_recvbuf(), pq_setkeepalivescount(), pq_setkeepalivesidle(), pq_setkeepalivesinterval(), pq_settcpusertimeout(), pq_startmsgread(), PQconninfoParse(), PQsetvalue(), PreCommit_CheckForSerializationFailure(), PreCommit_Notify(), PreCommit_Portals(), predicatelock_twophase_recover(), PrefetchBuffer(), prepare_cb_wrapper(), prepare_sql_fn_parse_info(), PrepareForIncrementalBackup(), PrepareQuery(), PrepareRedoAdd(), PrepareTransaction(), preprocess_grouping_sets(), prepTuplestoreResult(), PreventCommandDuringRecovery(), PreventCommandIfParallelMode(), PreventCommandIfReadOnly(), PreventInTransactionBlock(), printtup_prepare_info(), ProcArrayAdd(), ProcedureCreate(), process_function_rte_ref(), process_matched_tle(), process_owned_by(), process_pm_child_exit(), process_pm_pmsignal(), process_pm_reload_request(), process_pm_shutdown_request(), process_postgres_switches(), process_syncing_tables_for_apply(), ProcessCancelRequestPacket(), ProcessConfigFileInternal(), ProcessCopyOptions(), ProcessInterrupts(), ProcessLogMemoryContextInterrupt(), ProcessParallelApplyInterrupts(), ProcessParallelApplyMessage(), ProcessParallelApplyMessages(), ProcessParallelMessages(), ProcessPgArchInterrupts(), ProcessRecoveryConflictInterrupt(), ProcessRepliesIfAny(), ProcessSlotSyncInterrupts(), ProcessSSLStartup(), ProcessStandbyMessage(), ProcessStartupPacket(), ProcessSyncRequests(), ProcessTwoPhaseBuffer(), processTypesSpec(), ProcessUtilitySlow(), ProcSleep(), protect_out_of_mem(), prsd_headline(), prseof(), prssyntaxerror(), pub_collist_validate(), publication_add_relation(), publication_add_schema(), PublicationDropSchemas(), PublicationDropTables(), pushquery(), PushTransaction(), pushval_asis(), pushValue(), pushValue_internal(), pvsnprintf(), px_crypt_des(), px_crypt_shacrypt(), px_THROW_ERROR(), qtext_load_file(), qtext_store(), QTN2QT(), QualifiedNameGetCreationNamespace(), query_to_xml_internal(), queryin(), QueueCheckConstraintValidation(), QueueNNConstraintValidation(), quickdie(), random_numeric(), random_var(), range_constructor3(), range_minus_internal(), range_parse(), range_parse_bound(), range_parse_flags(), range_serialize(), range_union_internal(), RangeVarAdjustRelationPersistence(), RangeVarCallbackForAlterRelation(), RangeVarCallbackForAttachIndex(), RangeVarCallbackForDropRelation(), RangeVarCallbackForLockTable(), RangeVarCallbackForPolicy(), RangeVarCallbackForReindexIndex(), RangeVarCallbackForRenameRule(), RangeVarCallbackForRenameTrigger(), RangeVarCallbackMaintainsTable(), RangeVarCallbackOwnsRelation(), RangeVarGetAndCheckCreationNamespace(), RangeVarGetCreationNamespace(), RangeVarGetRelidExtended(), raw_heap_insert(), RE_compile(), RE_compile_and_cache(), RE_wchar_execute(), read_any_attr(), read_attr_value(), read_backup_label(), read_binary_file(), read_client_final_message(), read_client_first_message(), read_dictionary(), read_file_data_into_buffer(), read_objtype_from_string(), read_relmap_file(), read_server_final_message(), read_tablespace_map(), read_whole_file(), ReadArrayBinary(), ReadArrayDimensions(), ReadArrayStr(), ReadArrayToken(), ReadBufferExtended(), ReadCheckpointRecord(), ReadControlFile(), ReadDimensionInt(), ReadDirExtended(), ReadHead(), ReadNextXLogRecord(), ReadRecord(), readRecoverySignalFile(), ReadReplicationSlot(), readstoplist(), readTimeLineHistory(), ReadTwoPhaseFile(), ReadWalSummary(), ReassignOwnedObjects(), ReceiveCopyBinaryHeader(), RecheckDataDirLockFile(), recompute_limits(), record_cmp(), record_config_file_error(), record_eq(), record_image_cmp(), record_image_eq(), record_in(), record_recv(), recordDependencyOnCurrentExtension(), RecoverPreparedTransactions(), recovery_create_dbdir(), recoveryPausesHere(), RecoveryRequiresIntParameter(), recoveryStopsAfter(), recoveryStopsBefore(), RecreateTwoPhaseFile(), recursive_revoke(), recv_password_packet(), refresh_by_match_merge(), RefreshMatViewByOid(), refuseDupeIndexAttach(), regclassin(), regcollationin(), regcomp_auth_token(), regconfigin(), regdictionaryin(), regex_fixed_prefix(), regexp_count(), regexp_fixed_prefix(), regexp_instr(), regexp_like(), regexp_match(), regexp_split_to_array(), regexp_split_to_table(), regexp_substr(), register_dirty_segment(), RegisterBackgroundWorker(), RegisterCustomRmgr(), RegisterExtensibleNodeEntry(), RegisterTimeout(), regnamespacein(), regoperatorin(), regoperin(), regprocedurein(), regprocin(), REGRESS_exec_check_perms(), REGRESS_object_access_hook(), REGRESS_object_access_hook_str(), REGRESS_utility_command(), regrolein(), reindex_index(), reindex_relation(), ReindexMultipleInternal(), ReindexMultipleTables(), ReindexRelationConcurrently(), ReindexTable(), reject_target_detail(), relation_statistics_update(), RelationBuildPartitionKey(), RelationCopyStorage(), RelationGetBufferForTuple(), RelationSetNewRelfilenumber(), ReleaseOneSerializableXact(), ReleaseSavepoint(), RememberAllDependentForRebuilding(), remove_dbtablespaces(), remove_tablespace_symlink(), RemoveExtensionById(), RemoveInheritance(), RemoveObjects(), RemovePgTempFilesInDir(), RemovePgTempRelationFilesInDbspace(), RemovePolicyById(), RemoveRelations(), RemoveRewriteRuleById(), RemoveSubscriptionRel(), RemoveTriggerById(), RemoveTwoPhaseFile(), RemoveUserMapping(), RemoveWalSummaryIfOlderThan(), RemoveXlogFile(), rename_constraint_internal(), rename_policy(), renameatt(), renameatt_check(), renameatt_internal(), RenameConstraint(), RenameConstraintById(), RenameDatabase(), RenameEnumLabel(), RenameRelation(), RenameRelationInternal(), RenameRewriteRule(), RenameRole(), RenameSchema(), RenameTableSpace(), renametrig(), renametrig_internal(), RenameType(), RenameTypeInternal(), ReorderBufferCleanupSerializedTXNs(), ReorderBufferRestoreChanges(), ReorderBufferRestoreCleanup(), ReorderBufferSerializeChange(), ReorderBufferSerializeTXN(), repeat(), replace_percent_placeholders(), replace_rte_variables_mutator(), replace_text_regexp(), ReplaceVarFromTargetList(), ReplicationSlotAcquire(), ReplicationSlotAlter(), ReplicationSlotCreate(), ReplicationSlotDrop(), ReplicationSlotDropAtPubNode(), ReplicationSlotDropPtr(), ReplicationSlotRelease(), ReplicationSlotsDropDBSlots(), ReplicationSlotValidateName(), replorigin_advance(), replorigin_by_name(), replorigin_by_oid(), replorigin_check_prerequisites(), replorigin_create(), replorigin_session_reset(), replorigin_session_setup(), replorigin_state_clear(), ReplSlotSyncWorkerMain(), report_invalid_encoding(), report_name_conflict(), report_namespace_conflict(), report_newlocale_failure(), report_untranslatable_char(), ReportApplyConflict(), reportDependentObjects(), ReportNotNullViolationError(), ReportSlotConnectionError(), ReportSlotInvalidation(), ReportTemporaryFileUsage(), RequestCheckpoint(), rescanLatestTimeLine(), reserveAllocatedDesc(), ResetUnloggedRelationsInDbspaceDir(), ResetUnloggedRelationsInTablespaceDir(), resolve_anyarray_from_others(), resolve_anyelement_from_others(), resolve_anymultirange_from_others(), resolve_anyrange_from_others(), resolve_column_ref(), resolve_unique_index_expr(), ResolveOpClass(), RestoreArchive(), RestoreArchivedFile(), RestoreGUCState(), RestoreSlotFromDisk(), restrict_and_check_grant(), revalidate_rectypeid(), RevalidateCachedQuery(), revmap_physical_extend(), RewriteQuery(), rewriteRuleAction(), rewriteSearchAndCycle(), rewriteTargetListIU(), rewriteTargetView(), ri_CheckTrigger(), ri_FetchConstraintInfo(), RI_FKey_check(), RI_Initial_Check(), ri_PerformCheck(), ri_ReportViolation(), RmgrNotFound(), rollback_prepared_cb_wrapper(), RollbackToSavepoint(), rpad(), run_apply_worker(), run_ssl_passphrase_command(), sanity_check_array(), sanity_check_tid_array(), SanityCheckBackgroundWorker(), satisfies_hash_partition(), SaveSlotToPath(), scanNameSpaceForRefname(), scanNameSpaceForRelid(), scanner_yyerror(), scanNSItemForColumn(), scanRTEForColumn(), scram_exchange(), scram_init(), scram_verify_plain_password(), secure_open_gssapi(), secure_read(), secure_write(), seg_yyerror(), select_common_collation(), select_common_type(), select_common_type_from_oids(), select_perl_context(), SendBackupManifest(), SendBaseBackup(), SendCancelRequest(), sendDir(), sendFile(), SendFunctionResult(), sendTablespace(), SendTimeLineHistory(), sepgsql_attribute_relabel(), sepgsql_audit_log(), sepgsql_avc_check_perms_label(), sepgsql_avc_init(), sepgsql_avc_unlabeled(), sepgsql_client_auth(), sepgsql_compute_avd(), sepgsql_compute_create(), sepgsql_get_label(), sepgsql_init_client_label(), sepgsql_mcstrans_in(), sepgsql_mcstrans_out(), sepgsql_object_relabel(), sepgsql_relation_relabel(), sepgsql_restorecon(), sepgsql_set_client_label(), sepgsql_utility_command(), serialize_expr_stats(), serialize_prepare_info(), server_check_detail(), ServerLoop(), set_authn_id(), set_config_by_name(), set_config_with_handle(), set_max_safe_fds(), set_rot13(), set_stats_slot(), set_var_from_non_decimal_integer_str(), set_var_from_str(), setCompoundAffixFlagValue(), SetDefaultACL(), SetOffsetVacuumLimit(), setPath(), setPathArray(), setPathObject(), SetPossibleUnsafeConflict(), SetRWConflict(), setSchemaName(), setseed(), SetSerializableTransactionSnapshot(), setTargetTable(), SetTransactionIdLimit(), SetTransactionSnapshot(), Setup_AF_UNIX(), setup_background_workers(), setup_dynamic_shared_memory(), setup_pct_info(), setup_regexp_matches(), setup_test_matches(), SetUserIdAndContext(), SharedFileSetAttach(), shdepDropOwned(), shdepLockAndCheckObject(), shdepReassignOwned(), shell_archive_file(), shell_check_detail(), shell_finish_command(), shell_get_sink(), shell_in(), shell_out(), shell_run_command(), shell_send_data(), shm_mq_receive(), shm_mq_sendv(), shm_toc_allocate(), shm_toc_insert(), ShmemAlloc(), ShmemAllocUnlocked(), ShmemInitStruct(), should_apply_changes_for_rel(), should_refetch_tuple(), show_debug(), ShutdownXLOG(), similar_escape_internal(), SimpleLruTruncate(), SlabContextCreate(), slot_modify_data(), slot_store_data(), slotsync_reread_config(), SlruPhysicalReadPage(), SlruReportIOError(), SnapBuildFindSnapshot(), SnapBuildInitialSnapshot(), SnapBuildRestore(), SnapBuildRestoreContents(), SnapBuildRestoreSnapshot(), SnapBuildSerialize(), SnapBuildSnapshotExists(), socket_set_nonblocking(), SocketBackend(), sort(), spgadjustmembers(), spgdoinsert(), spgFormInnerTuple(), spgFormNodeTuple(), spgGetCache(), spgvalidate(), SPI_cursor_open_internal(), split_part(), sql_compile_callback(), sql_postrewrite_callback(), sqrt_var(), ssl_extension_info(), standard_ProcessUtility(), StandbySlotsHaveCaughtup(), StartBackgroundWorker(), StartChildProcess(), StartLogicalReplication(), StartReplication(), StartupDecodingContext(), StartupReplicationOrigin(), StartupReplicationSlots(), StartupRequestWalReceiverRestart(), StartupXLOG(), stats_check_arg_array(), stats_check_arg_pair(), stats_check_arg_type(), stats_check_required_arg(), stats_fill_fcinfo_from_arg_pairs(), stats_lock_check_privileges(), stats_lookup_relid(), stop_skipping_changes(), storeOperators(), StorePreparedStatement(), storeProcedures(), StoreRelCheck(), storeRow(), str_casefold(), str_initcap(), str_tolower(), str_toupper(), str_udeescape(), stream_abort_cb_wrapper(), stream_change_cb_wrapper(), stream_commit_cb_wrapper(), stream_prepare_cb_wrapper(), stream_start_cb_wrapper(), stream_stop_cb_wrapper(), string2ean(), string_to_privilege(), string_to_uuid(), stringToQualifiedNameList(), strlower_libc_mb(), strtitle_libc_mb(), strupper_libc_mb(), sts_parallel_scan_next(), sts_read_tuple(), substitute_grouped_columns_mutator(), substitute_path_macro(), SummarizeWAL(), suppress_redundant_updates_trigger(), SV_to_JsonbValue(), SwitchToUntrustedUser(), SyncDataDirectory(), synchronize_one_slot(), synchronize_slots(), SyncPostCheckpoint(), SyncRepReleaseWaiters(), SyncRepWaitForLSN(), SysLogger_Start(), SysLoggerMain(), systable_beginscan_ordered(), systable_inplace_update_begin(), system_beginsamplescan(), system_rows_beginsamplescan(), system_time_beginsamplescan(), table_tuple_get_latest_tid(), tablesample_init(), TablespaceCreateDbspace(), TargetPrivilegesCheck(), tblspc_redo(), TerminateOtherDBBackends(), test_copy_to_callback(), test_enc_conversion(), test_re_compile(), test_re_execute(), test_shm_mq(), test_shm_mq_main(), test_shm_mq_pipelined(), text_format(), text_format_append_string(), text_format_parse_digits(), text_format_parse_format(), text_format_string_conversion(), text_overlay(), text_starts_with(), text_substring(), text_to_bits(), text_to_stavalues(), textarray_to_strvaluelist(), textregexreplace(), textregexreplace_extended(), textToQualifiedNameList(), tfuncInitialize(), tfuncLoadRows(), thesaurus_init(), thesaurusRead(), throw_tcl_error(), tidin(), time_mi_interval(), time_part_common(), time_pl_interval(), time_recv(), timestamp2timestamptz_opt_overflow(), timestamp_age(), timestamp_bin(), timestamp_date(), timestamp_in(), timestamp_izone(), timestamp_mi(), timestamp_out(), timestamp_part_common(), timestamp_pl_interval(), timestamp_recv(), timestamp_time(), timestamp_to_char(), timestamp_trunc(), timestamp_zone(), timestamptz2timestamp(), timestamptz_age(), timestamptz_bin(), timestamptz_date(), timestamptz_in(), timestamptz_izone(), timestamptz_out(), timestamptz_part_common(), timestamptz_pl_interval_internal(), timestamptz_recv(), timestamptz_time(), timestamptz_timetz(), timestamptz_to_char(), timestamptz_trunc_internal(), timestamptz_zone(), timetz_izone(), timetz_mi_interval(), timetz_part_common(), timetz_pl_interval(), timetz_recv(), timetz_zone(), tliSwitchPoint(), to_ascii_enc(), to_ascii_encname(), to_cb(), to_date(), to_json(), to_jsonb(), to_timestamp(), tokenize_auth_file(), tokenize_include_file(), TopologicalSort(), tqueueReceiveSlot(), TransactionIdGetCommitTsData(), TransactionIdInRecentPast(), TransactionIdIsInProgress(), transformAExprNullIf(), transformAggregateCall(), transformAlterTableStmt(), transformArrayExpr(), transformAssignedExpr(), transformAssignmentIndirection(), transformAssignmentSubscripts(), transformCaseExpr(), transformCoalesceExpr(), transformCollateClause(), transformColumnDefinition(), transformColumnNameList(), transformColumnRef(), transformColumnType(), transformConstraintAttrs(), transformContainerSubscripts(), transformCreateStmt(), transformCreateTableAsStmt(), transformDeclareCursorStmt(), transformDistinctClause(), transformDistinctOnClause(), transformExprRecurse(), transformFkeyCheckAttrs(), transformFkeyGetPrimaryKey(), transformFrameOffset(), transformFromClauseItem(), transformGenericOptions(), transformGroupingFunc(), transformGroupingSet(), TransformGUCArray(), transformIndexConstraint(), transformIndexStmt(), transformIndirection(), transformInsertRow(), transformJsonAggConstructor(), transformJsonArrayQueryConstructor(), transformJsonBehavior(), transformJsonFuncExpr(), transformJsonIsPredicate(), transformJsonOutput(), transformJsonParseArg(), transformJsonParseExpr(), transformJsonReturning(), transformJsonSerializeExpr(), transformJsonTable(), transformJsonTableColumns(), transformJsonValueExpr(), transformLimitClause(), transformLockingClause(), transformMergeStmt(), transformMergeSupportFunc(), transformMultiAssignRef(), transformOnConflictArbiter(), transformParamRef(), transformPartitionBound(), transformPartitionBoundValue(), transformPartitionCmd(), transformPartitionRangeBounds(), transformPartitionSpec(), transformPLAssignStmt(), TransformPubWhereClauses(), transformRangeFunction(), transformRangeTableFunc(), transformRangeTableSample(), transformRelOptions(), transformReturningClause(), transformRowExpr(), transformRuleStmt(), transformSelectStmt(), transformSetOperationStmt(), transformSetOperationTree(), transformStatsStmt(), transformSubLink(), transformTableConstraint(), transformTableLikeClause(), transformTypeCast(), transformUpdateTargetList(), transformValuesClause(), transformWindowDefinitions(), transformWindowFuncCall(), transformWithClause(), transformXmlExpr(), transformXmlSerialize(), translate(), triggered_change_notification(), trim_array(), truncate_check_activity(), truncate_check_rel(), truncate_identifier(), TruncateMultiXact(), tryAttachPartitionForeignKey(), ts_headline_byid_opt(), ts_headline_json_byid_opt(), ts_headline_jsonb_byid_opt(), ts_stat_sql(), tsquery_phrase_distance(), tsquery_rewrite_query(), tsvector_concat(), tsvector_filter(), tsvector_update_trigger(), tsvectorin(), ttdummy(), tts_buffer_heap_getsysattr(), tts_buffer_is_current_xact_tuple(), tts_heap_getsysattr(), tts_heap_is_current_xact_tuple(), tts_minimal_getsysattr(), tts_minimal_is_current_xact_tuple(), tts_virtual_getsysattr(), tts_virtual_is_current_xact_tuple(), tuple_data_split(), tuple_data_split_internal(), tupledesc_match(), tuples_equal(), tuplestore_copy_read_pointer(), tuplestore_gettuple(), tuplestore_puttuple_common(), tuplestore_rescan(), tuplestore_select_read_pointer(), TypeCreate(), TypeGetTupleDesc(), typenameType(), typenameTypeMod(), TypeShellMake(), typeStringToTypeName(), uint32in_subr(), uint64in_subr(), unaccent_dict(), unaccent_init(), unicode_assigned(), unicode_norm_form_from_string(), unique_key_recheck(), uniqueifyJsonbObject(), unistr(), unknown_attribute(), unlink_if_exists_fname(), unlink_initfile(), UnlinkLockFiles(), update_and_persist_local_synced_slot(), update_controlfile(), update_local_synced_slot(), update_metainfo_datafile(), UserAbortTransactionBlock(), utf8_to_iso8859(), utf8_to_win(), UtfToLocal(), uuid_generate_internal(), vac_bulkdel_one_index(), vac_cleanup_one_index(), vac_truncate_clog(), vacuum(), vacuum_get_cutoffs(), vacuum_is_permitted_for_relation(), vacuum_open_relation(), vacuum_rel(), validate(), validate_ddl_tags(), validate_kvpair(), validate_option_array_item(), validate_pkattnums(), validate_relation_kind(), validate_remote_info(), validate_string_option(), validate_table_rewrite_tags(), validate_token_format(), validateConnectbyTupleDesc(), validateDomainCheckConstraint(), validateDomainNotNullConstraint(), validateFkOnDeleteSetColumns(), validateInfiniteBounds(), ValidateInputLSNs(), ValidateJoinEstimator(), ValidateOperatorReference(), ValidatePgVersion(), validateRecoveryParameters(), ValidateRestrictionEstimator(), ValidateSlotSyncParams(), ValidateXLOGDirectoryStructure(), varbit(), varbit_in(), varbit_recv(), varchar(), varchar_input(), variable_coerce_param_hook(), variable_paramref_hook(), varstr_levenshtein(), verify_brin_page(), verify_dictoptions(), verify_gist_page(), verify_hash_page(), verify_heapam(), verify_message(), verifyPartitionIndexNotNull(), VirtualXactLock(), wait_for_workers_to_become_ready(), WaitEventCustomNew(), WaitEventSetWaitBlock(), WaitForParallelWorkersToAttach(), WaitForParallelWorkersToExit(), WaitForParallelWorkersToFinish(), WaitForProcSignalBarrier(), WaitForWalSummarization(), WaitXLogInsertionsToFinish(), wal_segment_open(), WalRcvFetchTimeLineHistoryFiles(), WALReadFromBuffers(), WALReadRaiseError(), WalReceiverMain(), WalSndCheckTimeOut(), WalSndSegmentOpen(), widget_in(), width_bucket_array(), width_bucket_float8(), width_bucket_numeric(), win_to_utf8(), window_nth_value(), window_ntile(), worker_spi_launch(), write_auto_conf_file(), write_relcache_init_file(), write_relmap_file(), WriteControlFile(), writeTimeLineHistory(), writeTimeLineHistoryFile(), WriteWalSummary(), X509_NAME_field_to_text(), X509_NAME_to_cstring(), xlog_decode(), xlog_redo(), XLogArchiveForceDone(), XLogArchiveNotify(), XLogFileClose(), XLogFileCopy(), XLogFileInit(), XLogFileInitInternal(), XLogFileOpen(), XLogFileRead(), XLogFileReadAnyTLI(), XLogInitNewTimeline(), XLogPageRead(), XLogPrefetcherReadRecord(), XlogReadTwoPhaseData(), xlogrecovery_redo(), XLogRestorePoint(), XLogWalRcvClose(), XLogWalRcvWrite(), XLogWrite(), xmlcomment(), xmlpi(), XmlTableGetValue(), XmlTableSetColumnFilter(), XmlTableSetNamespace(), XmlTableSetRowFilter(), xmltotext_with_options(), xmlvalidate(), xpath_table(), and xslt_process().

◆ errmsg_internal()

int errmsg_internal ( const char *  fmt,
  ... 
)

Definition at line 1158 of file elog.c.

1159{
1161 MemoryContext oldcontext;
1162
1165 oldcontext = MemoryContextSwitchTo(edata->assoc_context);
1166
1167 edata->message_id = fmt;
1168 EVALUATE_MESSAGE(edata->domain, message, false, false);
1169
1170 MemoryContextSwitchTo(oldcontext);
1172 return 0; /* return value does not matter */
1173}

References ErrorData::assoc_context, CHECK_STACK_DEPTH, ErrorData::domain, errordata, errordata_stack_depth, EVALUATE_MESSAGE, MemoryContextSwitchTo(), ErrorData::message_id, and recursion_depth.

Referenced by _bt_binsrch_insert(), _bt_get_endpoint(), _bt_insert_parent(), _bt_insertonpg(), _bt_lock_subtree_parent(), _bt_mark_page_halfdead(), _bt_pagedel(), _bt_preprocess_array_keys_final(), _bt_split(), _bt_unlink_halfdead_page(), _dosmaperr(), AlterSubscription_refresh(), apply_handle_begin_prepare(), apply_handle_commit(), apply_handle_origin(), apply_handle_prepare(), apply_handle_stream_abort(), apply_handle_stream_commit(), apply_handle_stream_prepare(), apply_handle_stream_start(), apply_handle_stream_stop(), ApplyLauncherMain(), apw_dump_now(), ATRewriteTable(), AutoVacLauncherMain(), AutoVacLauncherShutdown(), AutoVacWorkerMain(), BackendInitialize(), BackendStartup(), BackgroundWorkerStateChange(), before_shmem_exit(), BeginCopyFrom(), bloom_get_procinfo(), brinGetTupleForHeapBlock(), bt_check_every_level(), bt_check_level_from_leftmost(), bt_downlink_missing_check(), bt_leftmost_ignoring_half_dead(), bt_recheck_sibling_links(), bt_right_page_check_scankey(), bt_target_page_check(), BTreeTupleGetHeapTIDCareful(), btvacuumpage(), buffer_readv_report(), build_attrmap_by_position(), byteaout(), call_bool_check_hook(), call_enum_check_hook(), call_int_check_hook(), call_real_check_hook(), call_string_check_hook(), check_agglevels_and_constraints(), check_default_partition_contents(), check_srf_call_placement(), ClosePostmasterPorts(), CompactCheckpointerRequestQueue(), CopyXLogRecordToWAL(), CountChildren(), create_and_test_bloom(), CreateCheckPoint(), CreateRestartPoint(), dblink_res_error(), DefineIndex(), do_analyze_rel(), elog_node_display(), enforce_generic_type_consistency(), errno_from_string(), exec_bind_message(), exec_parse_message(), exec_replication_command(), exec_stmt_assert(), exec_stmt_raise(), ExecuteRecoveryCommand(), ForgetBackgroundWorker(), fprintf_to_ereport(), FreezeMultiXactId(), generateSerialExtraStmts(), get_error_stack_entry(), get_object_property_data(), GetConnection(), GetFileBackupMethod(), GetOldestUnsummarizedLSN(), GetSafeSnapshot(), GetWALBlockInfo(), handle_streamed_transaction(), hashagg_batch_read(), heap_fetch_toast_slice(), heap_getnext(), heap_inplace_lock(), heap_pre_freeze_checks(), heap_prepare_freeze_tuple(), heap_vacuum_rel(), heapam_index_build_range_scan(), heapam_index_validate_scan(), heapam_tuple_lock(), inclusion_get_procinfo(), index_build(), index_delete_check_htid(), info_cb(), InitPostmasterChild(), InitPostmasterDeathWatchHandle(), InitWalRecovery(), InsertOneValue(), inv_seek(), inv_truncate(), IpcSemaphoreInitialize(), issue_xlog_fsync(), llvm_compile_module(), load_critical_index(), load_dh_buffer(), load_libraries(), logicalrep_worker_launch(), lz4_decompress_datum(), lz4_decompress_datum_slice(), manifest_report_error(), MemoryContextStatsDetail(), MemoryContextStatsInternal(), MemoryContextStatsPrint(), minmax_multi_get_procinfo(), NotNullImpliedByRelConstraints(), on_proc_exit(), on_shmem_exit(), palloc_btree_page(), PerformAuthentication(), pg_GSS_error(), pg_tzenumerate_next(), pgfdw_report_error(), pglz_decompress_datum(), pglz_decompress_datum_slice(), PGSharedMemoryCreate(), pgstat_discard_stats(), pgwin32_recv(), pgwin32_signal_initialize(), pgwin32_waitforsinglesocket(), PLy_elog_impl(), PLy_output(), PostmasterMain(), PrepareForIncrementalBackup(), process_pm_child_exit(), process_pm_pmsignal(), process_pm_reload_request(), process_pm_shutdown_request(), ProcessInterrupts(), ProcessSyncRequests(), ProcessWalSummarizerInterrupts(), ProcSleep(), QueuePartitionConstraintValidation(), read_backup_label(), ReadRecord(), register_dirty_segment(), RegisterBackgroundWorker(), RelationCacheInitializePhase3(), RemoveWalSummaryIfOlderThan(), RemoveXlogFile(), replication_yyerror(), reportDependentObjects(), ReportWalSummaryError(), RestoreArchivedFile(), run_apply_worker(), secure_open_server(), SendCancelRequest(), setitimer(), SetMultiXactIdLimit(), SetOffsetVacuumLimit(), SetTransactionIdLimit(), shell_archive_file(), ShowTransactionStateRec(), ShowUsage(), signal_child(), SlruInternalDeleteSegment(), SnapBuildFindSnapshot(), SocketBackend(), StartBackgroundWorker(), StartupXLOG(), statistic_proc_security_check(), summarizer_read_local_xlog_page(), SummarizeWAL(), synchronize_one_slot(), SyncRepInitConfig(), SysLoggerMain(), transformColumnRef(), transformSubLink(), transformWindowFuncCall(), TranslateSocketError(), TwoPhaseTransactionGid(), update_local_synced_slot(), UpdateMinRecoveryPoint(), vac_update_relstats(), validateForeignKeyConstraint(), verifyBackupPageConsistency(), WalRcvFetchTimeLineHistoryFiles(), WalSndLoop(), WalSummarizerMain(), write_item(), write_relcache_init_file(), XLogPageRead(), XLogReadBufferForRedoExtended(), XLogRecordAssemble(), XLogRegisterBufData(), XLogRegisterData(), XLogWalRcvProcessMsg(), and xml_out_internal().

◆ errmsg_plural()

◆ error_severity()

const char * error_severity ( int  elevel)

Definition at line 3728 of file elog.c.

3729{
3730 const char *prefix;
3731
3732 switch (elevel)
3733 {
3734 case DEBUG1:
3735 case DEBUG2:
3736 case DEBUG3:
3737 case DEBUG4:
3738 case DEBUG5:
3739 prefix = gettext_noop("DEBUG");
3740 break;
3741 case LOG:
3742 case LOG_SERVER_ONLY:
3743 prefix = gettext_noop("LOG");
3744 break;
3745 case INFO:
3746 prefix = gettext_noop("INFO");
3747 break;
3748 case NOTICE:
3749 prefix = gettext_noop("NOTICE");
3750 break;
3751 case WARNING:
3753 prefix = gettext_noop("WARNING");
3754 break;
3755 case ERROR:
3756 prefix = gettext_noop("ERROR");
3757 break;
3758 case FATAL:
3759 prefix = gettext_noop("FATAL");
3760 break;
3761 case PANIC:
3762 prefix = gettext_noop("PANIC");
3763 break;
3764 default:
3765 prefix = "???";
3766 break;
3767 }
3768
3769 return prefix;
3770}
#define gettext_noop(x)
Definition: c.h:1167
#define DEBUG3
Definition: elog.h:28
#define LOG_SERVER_ONLY
Definition: elog.h:32
#define WARNING_CLIENT_ONLY
Definition: elog.h:38
#define WARNING
Definition: elog.h:36
#define DEBUG2
Definition: elog.h:29
#define DEBUG1
Definition: elog.h:30
#define NOTICE
Definition: elog.h:35
#define INFO
Definition: elog.h:34
#define DEBUG5
Definition: elog.h:26
#define DEBUG4
Definition: elog.h:27

References DEBUG1, DEBUG2, DEBUG3, DEBUG4, DEBUG5, ERROR, FATAL, gettext_noop, INFO, LOG, LOG_SERVER_ONLY, NOTICE, PANIC, WARNING, and WARNING_CLIENT_ONLY.

Referenced by send_message_to_frontend(), send_message_to_server_log(), write_csvlog(), and write_jsonlog().

◆ errposition()

int errposition ( int  cursorpos)

Definition at line 1468 of file elog.c.

1469{
1471
1472 /* we don't bother incrementing recursion_depth */
1474
1475 edata->cursorpos = cursorpos;
1476
1477 return 0; /* return value does not matter */
1478}
int cursorpos
Definition: elog.h:444

References CHECK_STACK_DEPTH, ErrorData::cursorpos, errordata, and errordata_stack_depth.

Referenced by _SPI_error_callback(), executor_errposition(), function_parse_error_transpose(), import_error_callback(), parser_errposition(), scanner_errposition(), script_error_callback(), sql_compile_error_callback(), sql_exec_error_callback(), and sql_inline_error_callback().

◆ errsave_finish()

void errsave_finish ( struct Node context,
const char *  filename,
int  lineno,
const char *  funcname 
)

Definition at line 682 of file elog.c.

684{
685 ErrorSaveContext *escontext = (ErrorSaveContext *) context;
687
688 /* verify stack depth before accessing *edata */
690
691 /*
692 * If errsave_start punted to errstart, then elevel will be ERROR or
693 * perhaps even PANIC. Punt likewise to errfinish.
694 */
695 if (edata->elevel >= ERROR)
696 {
697 errfinish(filename, lineno, funcname);
699 }
700
701 /*
702 * Else, we should package up the stack entry contents and deliver them to
703 * the caller.
704 */
706
707 /* Save the last few bits of error state into the stack entry */
709
710 /* Replace the LOG value that errsave_start inserted */
711 edata->elevel = ERROR;
712
713 /*
714 * We skip calling backtrace and context functions, which are more likely
715 * to cause trouble than provide useful context; they might act on the
716 * assumption that a transaction abort is about to occur.
717 */
718
719 /*
720 * Make a copy of the error info for the caller. All the subsidiary
721 * strings are already in the caller's context, so it's sufficient to
722 * flat-copy the stack entry.
723 */
724 escontext->error_data = palloc_object(ErrorData);
725 memcpy(escontext->error_data, edata, sizeof(ErrorData));
726
727 /* Exit error-handling context */
730}
#define pg_unreachable()
Definition: c.h:332
void errfinish(const char *filename, int lineno, const char *funcname)
Definition: elog.c:474
#define palloc_object(type)
Definition: fe_memutils.h:74
ErrorData * error_data
Definition: miscnodes.h:49

References CHECK_STACK_DEPTH, ErrorData::elevel, errfinish(), ERROR, ErrorSaveContext::error_data, errordata, errordata_stack_depth, filename, funcname, palloc_object, pg_unreachable, recursion_depth, and set_stack_entry_location().

◆ errsave_start()

bool errsave_start ( struct Node context,
const char *  domain 
)

Definition at line 630 of file elog.c.

631{
632 ErrorSaveContext *escontext;
633 ErrorData *edata;
634
635 /*
636 * Do we have a context for soft error reporting? If not, just punt to
637 * errstart().
638 */
639 if (context == NULL || !IsA(context, ErrorSaveContext))
640 return errstart(ERROR, domain);
641
642 /* Report that a soft error was detected */
643 escontext = (ErrorSaveContext *) context;
644 escontext->error_occurred = true;
645
646 /* Nothing else to do if caller wants no further details */
647 if (!escontext->details_wanted)
648 return false;
649
650 /*
651 * Okay, crank up a stack entry to store the info in.
652 */
653
655
656 /* Initialize data for this error frame */
657 edata = get_error_stack_entry();
658 edata->elevel = LOG; /* signal all is well to errsave_finish */
659 set_stack_entry_domain(edata, domain);
660 /* Select default errcode based on the assumed elevel of ERROR */
661 edata->sqlerrcode = ERRCODE_INTERNAL_ERROR;
662
663 /*
664 * Any allocations for this error state level should go into the caller's
665 * context. We don't need to pollute ErrorContext, or even require it to
666 * exist, in this code path.
667 */
669
671 return true;
672}
bool errstart(int elevel, const char *domain)
Definition: elog.c:343
static ErrorData * get_error_stack_entry(void)
Definition: elog.c:752
static void set_stack_entry_domain(ErrorData *edata, const char *domain)
Definition: elog.c:779
#define IsA(nodeptr, _type_)
Definition: nodes.h:164
bool details_wanted
Definition: miscnodes.h:48
bool error_occurred
Definition: miscnodes.h:47

References ErrorData::assoc_context, CurrentMemoryContext, ErrorSaveContext::details_wanted, ErrorData::elevel, ERROR, ErrorSaveContext::error_occurred, errstart(), get_error_stack_entry(), IsA, LOG, recursion_depth, set_stack_entry_domain(), and ErrorData::sqlerrcode.

◆ errstart()

bool errstart ( int  elevel,
const char *  domain 
)

Definition at line 343 of file elog.c.

344{
345 ErrorData *edata;
346 bool output_to_server;
347 bool output_to_client = false;
348 int i;
349
350 /*
351 * Check some cases in which we want to promote an error into a more
352 * severe error. None of this logic applies for non-error messages.
353 */
354 if (elevel >= ERROR)
355 {
356 /*
357 * If we are inside a critical section, all errors become PANIC
358 * errors. See miscadmin.h.
359 */
360 if (CritSectionCount > 0)
361 elevel = PANIC;
362
363 /*
364 * Check reasons for treating ERROR as FATAL:
365 *
366 * 1. we have no handler to pass the error to (implies we are in the
367 * postmaster or in backend startup).
368 *
369 * 2. ExitOnAnyError mode switch is set (initdb uses this).
370 *
371 * 3. the error occurred after proc_exit has begun to run. (It's
372 * proc_exit's responsibility to see that this doesn't turn into
373 * infinite recursion!)
374 */
375 if (elevel == ERROR)
376 {
377 if (PG_exception_stack == NULL ||
380 elevel = FATAL;
381 }
382
383 /*
384 * If the error level is ERROR or more, errfinish is not going to
385 * return to caller; therefore, if there is any stacked error already
386 * in progress it will be lost. This is more or less okay, except we
387 * do not want to have a FATAL or PANIC error downgraded because the
388 * reporting process was interrupted by a lower-grade error. So check
389 * the stack and make sure we panic if panic is warranted.
390 */
391 for (i = 0; i <= errordata_stack_depth; i++)
392 elevel = Max(elevel, errordata[i].elevel);
393 }
394
395 /*
396 * Now decide whether we need to process this report at all; if it's
397 * warning or less and not enabled for logging, just return false without
398 * starting up any error logging machinery.
399 */
400 output_to_server = should_output_to_server(elevel);
401 output_to_client = should_output_to_client(elevel);
402 if (elevel < ERROR && !output_to_server && !output_to_client)
403 return false;
404
405 /*
406 * We need to do some actual work. Make sure that memory context
407 * initialization has finished, else we can't do anything useful.
408 */
409 if (ErrorContext == NULL)
410 {
411 /* Oops, hard crash time; very little we can do safely here */
412 write_stderr("error occurred before error message processing is available\n");
413 exit(2);
414 }
415
416 /*
417 * Okay, crank up a stack entry to store the info in.
418 */
419
420 if (recursion_depth++ > 0 && elevel >= ERROR)
421 {
422 /*
423 * Oops, error during error processing. Clear ErrorContext as
424 * discussed at top of file. We will not return to the original
425 * error's reporter or handler, so we don't need it.
426 */
428
429 /*
430 * Infinite error recursion might be due to something broken in a
431 * context traceback routine. Abandon them too. We also abandon
432 * attempting to print the error statement (which, if long, could
433 * itself be the source of the recursive failure).
434 */
436 {
437 error_context_stack = NULL;
438 debug_query_string = NULL;
439 }
440 }
441
442 /* Initialize data for this error frame */
443 edata = get_error_stack_entry();
444 edata->elevel = elevel;
445 edata->output_to_server = output_to_server;
446 edata->output_to_client = output_to_client;
447 set_stack_entry_domain(edata, domain);
448 /* Select default errcode based on elevel */
449 if (elevel >= ERROR)
450 edata->sqlerrcode = ERRCODE_INTERNAL_ERROR;
451 else if (elevel >= WARNING)
452 edata->sqlerrcode = ERRCODE_WARNING;
453 else
454 edata->sqlerrcode = ERRCODE_SUCCESSFUL_COMPLETION;
455
456 /*
457 * Any allocations for this error state level should go into ErrorContext
458 */
460
462 return true;
463}
#define Max(x, y)
Definition: c.h:969
static bool should_output_to_client(int elevel)
Definition: elog.c:245
static bool should_output_to_server(int elevel)
Definition: elog.c:236
void write_stderr(const char *fmt,...)
Definition: elog.c:3799
bool ExitOnAnyError
Definition: globals.c:123
bool proc_exit_inprogress
Definition: ipc.c:40
void MemoryContextReset(MemoryContext context)
Definition: mcxt.c:383

References ErrorData::assoc_context, CritSectionCount, debug_query_string, ErrorData::elevel, ERROR, error_context_stack, ErrorContext, errordata, errordata_stack_depth, ExitOnAnyError, FATAL, get_error_stack_entry(), i, in_error_recursion_trouble(), Max, MemoryContextReset(), ErrorData::output_to_client, ErrorData::output_to_server, PANIC, PG_exception_stack, proc_exit_inprogress, recursion_depth, set_stack_entry_domain(), should_output_to_client(), should_output_to_server(), ErrorData::sqlerrcode, WARNING, and write_stderr().

Referenced by errsave_start(), errstart_cold(), and ThrowErrorData().

◆ errstart_cold()

pg_attribute_cold bool errstart_cold ( int  elevel,
const char *  domain 
)

Definition at line 327 of file elog.c.

328{
329 return errstart(elevel, domain);
330}

References errstart().

◆ FlushErrorState()

◆ format_elog_string()

char * format_elog_string ( const char *  fmt,
  ... 
)

Definition at line 1676 of file elog.c.

1677{
1678 ErrorData errdata;
1679 ErrorData *edata;
1680 MemoryContext oldcontext;
1681
1682 /* Initialize a mostly-dummy error frame */
1683 edata = &errdata;
1684 MemSet(edata, 0, sizeof(ErrorData));
1685 /* the default text domain is the backend's */
1687 /* set the errno to be used to interpret %m */
1689
1690 oldcontext = MemoryContextSwitchTo(ErrorContext);
1691
1692 edata->message_id = fmt;
1693 EVALUATE_MESSAGE(edata->domain, message, false, true);
1694
1695 MemoryContextSwitchTo(oldcontext);
1696
1697 return edata->message;
1698}
#define PG_TEXTDOMAIN(domain)
Definition: c.h:1185
#define MemSet(start, val, len)
Definition: c.h:991
static int save_format_errnumber
Definition: elog.c:1663
static const char * save_format_domain
Definition: elog.c:1664

References ErrorData::domain, ErrorContext, EVALUATE_MESSAGE, MemoryContextSwitchTo(), MemSet, ErrorData::message, ErrorData::message_id, PG_TEXTDOMAIN, save_format_domain, save_format_errnumber, and ErrorData::saved_errno.

◆ FreeErrorData()

◆ FreeErrorDataContents()

static void FreeErrorDataContents ( ErrorData edata)
static

Definition at line 1852 of file elog.c.

1853{
1854 if (edata->message)
1855 pfree(edata->message);
1856 if (edata->detail)
1857 pfree(edata->detail);
1858 if (edata->detail_log)
1859 pfree(edata->detail_log);
1860 if (edata->hint)
1861 pfree(edata->hint);
1862 if (edata->context)
1863 pfree(edata->context);
1864 if (edata->backtrace)
1865 pfree(edata->backtrace);
1866 if (edata->schema_name)
1867 pfree(edata->schema_name);
1868 if (edata->table_name)
1869 pfree(edata->table_name);
1870 if (edata->column_name)
1871 pfree(edata->column_name);
1872 if (edata->datatype_name)
1873 pfree(edata->datatype_name);
1874 if (edata->constraint_name)
1875 pfree(edata->constraint_name);
1876 if (edata->internalquery)
1877 pfree(edata->internalquery);
1878}

References ErrorData::backtrace, ErrorData::column_name, ErrorData::constraint_name, ErrorData::context, ErrorData::datatype_name, ErrorData::detail, ErrorData::detail_log, ErrorData::hint, ErrorData::internalquery, ErrorData::message, pfree(), ErrorData::schema_name, and ErrorData::table_name.

Referenced by errfinish(), and FreeErrorData().

◆ get_backend_type_for_log()

const char * get_backend_type_for_log ( void  )

Definition at line 2780 of file elog.c.

2781{
2782 const char *backend_type_str;
2783
2784 if (MyProcPid == PostmasterPid)
2785 backend_type_str = "postmaster";
2786 else if (MyBackendType == B_BG_WORKER)
2787 backend_type_str = MyBgworkerEntry->bgw_type;
2788 else
2789 backend_type_str = GetBackendTypeDesc(MyBackendType);
2790
2791 return backend_type_str;
2792}
pid_t PostmasterPid
Definition: globals.c:106
int MyProcPid
Definition: globals.c:47
@ B_BG_WORKER
Definition: miscadmin.h:345
const char * GetBackendTypeDesc(BackendType backendType)
Definition: miscinit.c:263
BackendType MyBackendType
Definition: miscinit.c:64
BackgroundWorker * MyBgworkerEntry
Definition: postmaster.c:200
char bgw_type[BGW_MAXLEN]
Definition: bgworker.h:92

References B_BG_WORKER, BackgroundWorker::bgw_type, GetBackendTypeDesc(), MyBackendType, MyBgworkerEntry, MyProcPid, and PostmasterPid.

Referenced by log_status_format(), write_csvlog(), and write_jsonlog().

◆ get_error_stack_entry()

static ErrorData * get_error_stack_entry ( void  )
static

Definition at line 752 of file elog.c.

753{
754 ErrorData *edata;
755
756 /* Allocate error frame */
759 {
760 /* Wups, stack not big enough */
761 errordata_stack_depth = -1; /* make room on stack */
762 ereport(PANIC, (errmsg_internal("ERRORDATA_STACK_SIZE exceeded")));
763 }
764
765 /* Initialize error frame to all zeroes/NULLs */
767 memset(edata, 0, sizeof(ErrorData));
768
769 /* Save errno immediately to ensure error parameter eval can't change it */
770 edata->saved_errno = errno;
771
772 return edata;
773}
#define unlikely(x)
Definition: c.h:347
#define ERRORDATA_STACK_SIZE
Definition: elog.c:144

References ereport, errmsg_internal(), errordata, errordata_stack_depth, ERRORDATA_STACK_SIZE, PANIC, ErrorData::saved_errno, and unlikely.

Referenced by errsave_start(), errstart(), GetErrorContextStack(), and ReThrowError().

◆ get_formatted_log_time()

char * get_formatted_log_time ( void  )

Definition at line 2683 of file elog.c.

2684{
2685 pg_time_t stamp_time;
2686 char msbuf[13];
2687
2688 /* leave if already computed */
2689 if (formatted_log_time[0] != '\0')
2690 return formatted_log_time;
2691
2692 if (!saved_timeval_set)
2693 {
2695 saved_timeval_set = true;
2696 }
2697
2698 stamp_time = (pg_time_t) saved_timeval.tv_sec;
2699
2700 /*
2701 * Note: we expect that guc.c will ensure that log_timezone is set up (at
2702 * least with a minimal GMT value) before Log_line_prefix can become
2703 * nonempty or CSV/JSON mode can be selected.
2704 */
2706 /* leave room for milliseconds... */
2707 "%Y-%m-%d %H:%M:%S %Z",
2708 pg_localtime(&stamp_time, log_timezone));
2709
2710 /* 'paste' milliseconds into place... */
2711 sprintf(msbuf, ".%03d", (int) (saved_timeval.tv_usec / 1000));
2712 memcpy(formatted_log_time + 19, msbuf, 4);
2713
2714 return formatted_log_time;
2715}
#define FORMATTED_TS_LEN
Definition: elog.c:159
static struct timeval saved_timeval
Definition: elog.c:156
int64 pg_time_t
Definition: pgtime.h:23
size_t pg_strftime(char *s, size_t maxsize, const char *format, const struct pg_tm *t)
Definition: strftime.c:128
struct pg_tm * pg_localtime(const pg_time_t *timep, const pg_tz *tz)
Definition: localtime.c:1344
PGDLLIMPORT pg_tz * log_timezone
Definition: pgtz.c:31
#define sprintf
Definition: port.h:241
int gettimeofday(struct timeval *tp, void *tzp)

References formatted_log_time, FORMATTED_TS_LEN, gettimeofday(), log_timezone, pg_localtime(), pg_strftime(), saved_timeval, saved_timeval_set, and sprintf.

Referenced by log_status_format(), write_csvlog(), and write_jsonlog().

◆ get_formatted_start_time()

char * get_formatted_start_time ( void  )

Definition at line 2733 of file elog.c.

2734{
2735 pg_time_t stamp_time = (pg_time_t) MyStartTime;
2736
2737 /* leave if already computed */
2738 if (formatted_start_time[0] != '\0')
2739 return formatted_start_time;
2740
2741 /*
2742 * Note: we expect that guc.c will ensure that log_timezone is set up (at
2743 * least with a minimal GMT value) before Log_line_prefix can become
2744 * nonempty or CSV/JSON mode can be selected.
2745 */
2747 "%Y-%m-%d %H:%M:%S %Z",
2748 pg_localtime(&stamp_time, log_timezone));
2749
2750 return formatted_start_time;
2751}
static char formatted_start_time[FORMATTED_TS_LEN]
Definition: elog.c:160
pg_time_t MyStartTime
Definition: globals.c:48

References formatted_start_time, FORMATTED_TS_LEN, log_timezone, MyStartTime, pg_localtime(), and pg_strftime().

Referenced by log_status_format(), write_csvlog(), and write_jsonlog().

◆ geterrcode()

int geterrcode ( void  )

Definition at line 1583 of file elog.c.

1584{
1586
1587 /* we don't bother incrementing recursion_depth */
1589
1590 return edata->sqlerrcode;
1591}

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::sqlerrcode.

Referenced by pcb_error_callback(), and scb_error_callback().

◆ geterrlevel()

int geterrlevel ( void  )

Definition at line 1600 of file elog.c.

1601{
1603
1604 /* we don't bother incrementing recursion_depth */
1606
1607 return edata->elevel;
1608}

References CHECK_STACK_DEPTH, ErrorData::elevel, errordata, and errordata_stack_depth.

Referenced by apply_error_callback().

◆ GetErrorContextStack()

char * GetErrorContextStack ( void  )

Definition at line 2081 of file elog.c.

2082{
2083 ErrorData *edata;
2084 ErrorContextCallback *econtext;
2085
2086 /*
2087 * Crank up a stack entry to store the info in.
2088 */
2090
2091 edata = get_error_stack_entry();
2092
2093 /*
2094 * Set up assoc_context to be the caller's context, so any allocations
2095 * done (which will include edata->context) will use their context.
2096 */
2098
2099 /*
2100 * Call any context callback functions to collect the context information
2101 * into edata->context.
2102 *
2103 * Errors occurring in callback functions should go through the regular
2104 * error handling code which should handle any recursive errors, though we
2105 * double-check above, just in case.
2106 */
2107 for (econtext = error_context_stack;
2108 econtext != NULL;
2109 econtext = econtext->previous)
2110 econtext->callback(econtext->arg);
2111
2112 /*
2113 * Clean ourselves off the stack, any allocations done should have been
2114 * using edata->assoc_context, which we set up earlier to be the caller's
2115 * context, so we're free to just remove our entry off the stack and
2116 * decrement recursion depth and exit.
2117 */
2120
2121 /*
2122 * Return a pointer to the string the caller asked for, which should have
2123 * been allocated in their context.
2124 */
2125 return edata->context;
2126}

References ErrorContextCallback::arg, ErrorData::assoc_context, ErrorContextCallback::callback, ErrorData::context, CurrentMemoryContext, error_context_stack, errordata_stack_depth, get_error_stack_entry(), ErrorContextCallback::previous, and recursion_depth.

Referenced by exec_stmt_getdiag().

◆ geterrposition()

int geterrposition ( void  )

Definition at line 1617 of file elog.c.

1618{
1620
1621 /* we don't bother incrementing recursion_depth */
1623
1624 return edata->cursorpos;
1625}

References CHECK_STACK_DEPTH, ErrorData::cursorpos, errordata, and errordata_stack_depth.

Referenced by _SPI_error_callback(), function_parse_error_transpose(), import_error_callback(), script_error_callback(), sql_compile_error_callback(), sql_exec_error_callback(), and sql_inline_error_callback().

◆ getinternalerrposition()

int getinternalerrposition ( void  )

Definition at line 1634 of file elog.c.

1635{
1637
1638 /* we don't bother incrementing recursion_depth */
1640
1641 return edata->internalpos;
1642}
int internalpos
Definition: elog.h:445

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::internalpos.

Referenced by function_parse_error_transpose().

◆ in_error_recursion_trouble()

bool in_error_recursion_trouble ( void  )

Definition at line 294 of file elog.c.

295{
296 /* Pull the plug if recurse more than once */
297 return (recursion_depth > 2);
298}

References recursion_depth.

Referenced by err_gettext(), err_sendstring(), errstart(), pgfdw_abort_cleanup(), pgfdw_abort_cleanup_begin(), and write_console().

◆ internalerrposition()

int internalerrposition ( int  cursorpos)

Definition at line 1484 of file elog.c.

1485{
1487
1488 /* we don't bother incrementing recursion_depth */
1490
1491 edata->internalpos = cursorpos;
1492
1493 return 0; /* return value does not matter */
1494}

References CHECK_STACK_DEPTH, errordata, errordata_stack_depth, and ErrorData::internalpos.

Referenced by _SPI_error_callback(), function_parse_error_transpose(), import_error_callback(), plpgsql_scanner_errposition(), PLy_elog_impl(), script_error_callback(), sql_compile_error_callback(), sql_exec_error_callback(), and sql_inline_error_callback().

◆ internalerrquery()

int internalerrquery ( const char *  query)

Definition at line 1504 of file elog.c.

1505{
1507
1508 /* we don't bother incrementing recursion_depth */
1510
1511 if (edata->internalquery)
1512 {
1513 pfree(edata->internalquery);
1514 edata->internalquery = NULL;
1515 }
1516
1517 if (query)
1518 edata->internalquery = MemoryContextStrdup(edata->assoc_context, query);
1519
1520 return 0; /* return value does not matter */
1521}
char * MemoryContextStrdup(MemoryContext context, const char *string)
Definition: mcxt.c:1686

References ErrorData::assoc_context, CHECK_STACK_DEPTH, errordata, errordata_stack_depth, ErrorData::internalquery, MemoryContextStrdup(), and pfree().

Referenced by _SPI_error_callback(), function_parse_error_transpose(), import_error_callback(), plpgsql_scanner_errposition(), PLy_elog_impl(), script_error_callback(), sql_compile_error_callback(), sql_exec_error_callback(), and sql_inline_error_callback().

◆ is_log_level_output()

static bool is_log_level_output ( int  elevel,
int  log_min_level 
)
inlinestatic

Definition at line 202 of file elog.c.

203{
204 if (elevel == LOG || elevel == LOG_SERVER_ONLY)
205 {
206 if (log_min_level == LOG || log_min_level <= ERROR)
207 return true;
208 }
209 else if (elevel == WARNING_CLIENT_ONLY)
210 {
211 /* never sent to log, regardless of log_min_level */
212 return false;
213 }
214 else if (log_min_level == LOG)
215 {
216 /* elevel != LOG */
217 if (elevel >= FATAL)
218 return true;
219 }
220 /* Neither is LOG */
221 else if (elevel >= log_min_level)
222 return true;
223
224 return false;
225}

References ERROR, FATAL, LOG, LOG_SERVER_ONLY, and WARNING_CLIENT_ONLY.

Referenced by check_log_of_query(), and should_output_to_server().

◆ log_line_prefix()

static void log_line_prefix ( StringInfo  buf,
ErrorData edata 
)
static

Definition at line 2833 of file elog.c.

2834{
2836}
void log_status_format(StringInfo buf, const char *format, ErrorData *edata)
Definition: elog.c:2842
char * Log_line_prefix
Definition: elog.c:110

References buf, Log_line_prefix, and log_status_format().

Referenced by send_message_to_server_log().

◆ log_status_format()

void log_status_format ( StringInfo  buf,
const char *  format,
ErrorData edata 
)

Definition at line 2842 of file elog.c.

2843{
2844 /* static counter for line numbers */
2845 static long log_line_number = 0;
2846
2847 /* has counter been reset in current process? */
2848 static int log_my_pid = 0;
2849 int padding;
2850 const char *p;
2851
2852 /*
2853 * This is one of the few places where we'd rather not inherit a static
2854 * variable's value from the postmaster. But since we will, reset it when
2855 * MyProcPid changes. MyStartTime also changes when MyProcPid does, so
2856 * reset the formatted start timestamp too.
2857 */
2858 if (log_my_pid != MyProcPid)
2859 {
2860 log_line_number = 0;
2861 log_my_pid = MyProcPid;
2863 }
2864 log_line_number++;
2865
2866 if (format == NULL)
2867 return; /* in case guc hasn't run yet */
2868
2869 for (p = format; *p != '\0'; p++)
2870 {
2871 if (*p != '%')
2872 {
2873 /* literal char, just copy */
2875 continue;
2876 }
2877
2878 /* must be a '%', so skip to the next char */
2879 p++;
2880 if (*p == '\0')
2881 break; /* format error - ignore it */
2882 else if (*p == '%')
2883 {
2884 /* string contains %% */
2886 continue;
2887 }
2888
2889
2890 /*
2891 * Process any formatting which may exist after the '%'. Note that
2892 * process_log_prefix_padding moves p past the padding number if it
2893 * exists.
2894 *
2895 * Note: Since only '-', '0' to '9' are valid formatting characters we
2896 * can do a quick check here to pre-check for formatting. If the char
2897 * is not formatting then we can skip a useless function call.
2898 *
2899 * Further note: At least on some platforms, passing %*s rather than
2900 * %s to appendStringInfo() is substantially slower, so many of the
2901 * cases below avoid doing that unless non-zero padding is in fact
2902 * specified.
2903 */
2904 if (*p > '9')
2905 padding = 0;
2906 else if ((p = process_log_prefix_padding(p, &padding)) == NULL)
2907 break;
2908
2909 /* process the option */
2910 switch (*p)
2911 {
2912 case 'a':
2913 if (MyProcPort)
2914 {
2915 const char *appname = application_name;
2916
2917 if (appname == NULL || *appname == '\0')
2918 appname = _("[unknown]");
2919 if (padding != 0)
2920 appendStringInfo(buf, "%*s", padding, appname);
2921 else
2922 appendStringInfoString(buf, appname);
2923 }
2924 else if (padding != 0)
2926 padding > 0 ? padding : -padding);
2927
2928 break;
2929 case 'b':
2930 {
2931 const char *backend_type_str = get_backend_type_for_log();
2932
2933 if (padding != 0)
2934 appendStringInfo(buf, "%*s", padding, backend_type_str);
2935 else
2936 appendStringInfoString(buf, backend_type_str);
2937 break;
2938 }
2939 case 'u':
2940 if (MyProcPort)
2941 {
2942 const char *username = MyProcPort->user_name;
2943
2944 if (username == NULL || *username == '\0')
2945 username = _("[unknown]");
2946 if (padding != 0)
2947 appendStringInfo(buf, "%*s", padding, username);
2948 else
2950 }
2951 else if (padding != 0)
2953 padding > 0 ? padding : -padding);
2954 break;
2955 case 'd':
2956 if (MyProcPort)
2957 {
2958 const char *dbname = MyProcPort->database_name;
2959
2960 if (dbname == NULL || *dbname == '\0')
2961 dbname = _("[unknown]");
2962 if (padding != 0)
2963 appendStringInfo(buf, "%*s", padding, dbname);
2964 else
2966 }
2967 else if (padding != 0)
2969 padding > 0 ? padding : -padding);
2970 break;
2971 case 'c':
2972 if (padding != 0)
2973 {
2974 char strfbuf[128];
2975
2976 snprintf(strfbuf, sizeof(strfbuf) - 1, INT64_HEX_FORMAT ".%x",
2978 appendStringInfo(buf, "%*s", padding, strfbuf);
2979 }
2980 else
2982 break;
2983 case 'p':
2984 if (padding != 0)
2985 appendStringInfo(buf, "%*d", padding, MyProcPid);
2986 else
2988 break;
2989
2990 case 'P':
2991 if (MyProc)
2992 {
2993 PGPROC *leader = MyProc->lockGroupLeader;
2994
2995 /*
2996 * Show the leader only for active parallel workers. This
2997 * leaves out the leader of a parallel group.
2998 */
2999 if (leader == NULL || leader->pid == MyProcPid)
3001 padding > 0 ? padding : -padding);
3002 else if (padding != 0)
3003 appendStringInfo(buf, "%*d", padding, leader->pid);
3004 else
3005 appendStringInfo(buf, "%d", leader->pid);
3006 }
3007 else if (padding != 0)
3009 padding > 0 ? padding : -padding);
3010 break;
3011
3012 case 'l':
3013 if (padding != 0)
3014 appendStringInfo(buf, "%*ld", padding, log_line_number);
3015 else
3016 appendStringInfo(buf, "%ld", log_line_number);
3017 break;
3018 case 'm':
3019 /* force a log timestamp reset */
3020 formatted_log_time[0] = '\0';
3021 (void) get_formatted_log_time();
3022
3023 if (padding != 0)
3024 appendStringInfo(buf, "%*s", padding, formatted_log_time);
3025 else
3027 break;
3028 case 't':
3029 {
3030 pg_time_t stamp_time = (pg_time_t) time(NULL);
3031 char strfbuf[128];
3032
3033 pg_strftime(strfbuf, sizeof(strfbuf),
3034 "%Y-%m-%d %H:%M:%S %Z",
3035 pg_localtime(&stamp_time, log_timezone));
3036 if (padding != 0)
3037 appendStringInfo(buf, "%*s", padding, strfbuf);
3038 else
3039 appendStringInfoString(buf, strfbuf);
3040 }
3041 break;
3042 case 'n':
3043 {
3044 char strfbuf[128];
3045
3046 if (!saved_timeval_set)
3047 {
3049 saved_timeval_set = true;
3050 }
3051
3052 snprintf(strfbuf, sizeof(strfbuf), "%ld.%03d",
3053 (long) saved_timeval.tv_sec,
3054 (int) (saved_timeval.tv_usec / 1000));
3055
3056 if (padding != 0)
3057 appendStringInfo(buf, "%*s", padding, strfbuf);
3058 else
3059 appendStringInfoString(buf, strfbuf);
3060 }
3061 break;
3062 case 's':
3063 {
3065
3066 if (padding != 0)
3067 appendStringInfo(buf, "%*s", padding, start_time);
3068 else
3070 }
3071 break;
3072 case 'i':
3073 if (MyProcPort)
3074 {
3075 const char *psdisp;
3076 int displen;
3077
3078 psdisp = get_ps_display(&displen);
3079 if (padding != 0)
3080 appendStringInfo(buf, "%*s", padding, psdisp);
3081 else
3082 appendBinaryStringInfo(buf, psdisp, displen);
3083 }
3084 else if (padding != 0)
3086 padding > 0 ? padding : -padding);
3087 break;
3088 case 'L':
3089 {
3090 const char *local_host;
3091
3092 if (MyProcPort)
3093 {
3094 if (MyProcPort->local_host[0] == '\0')
3095 {
3096 /*
3097 * First time through: cache the lookup, since it
3098 * might not have trivial cost.
3099 */
3103 sizeof(MyProcPort->local_host),
3104 NULL, 0,
3105 NI_NUMERICHOST | NI_NUMERICSERV);
3106 }
3107 local_host = MyProcPort->local_host;
3108 }
3109 else
3110 {
3111 /* Background process, or connection not yet made */
3112 local_host = "[none]";
3113 }
3114 if (padding != 0)
3115 appendStringInfo(buf, "%*s", padding, local_host);
3116 else
3117 appendStringInfoString(buf, local_host);
3118 }
3119 break;
3120 case 'r':
3122 {
3123 if (padding != 0)
3124 {
3125 if (MyProcPort->remote_port && MyProcPort->remote_port[0] != '\0')
3126 {
3127 /*
3128 * This option is slightly special as the port
3129 * number may be appended onto the end. Here we
3130 * need to build 1 string which contains the
3131 * remote_host and optionally the remote_port (if
3132 * set) so we can properly align the string.
3133 */
3134
3135 char *hostport;
3136
3137 hostport = psprintf("%s(%s)", MyProcPort->remote_host, MyProcPort->remote_port);
3138 appendStringInfo(buf, "%*s", padding, hostport);
3139 pfree(hostport);
3140 }
3141 else
3142 appendStringInfo(buf, "%*s", padding, MyProcPort->remote_host);
3143 }
3144 else
3145 {
3146 /* padding is 0, so we don't need a temp buffer */
3148 if (MyProcPort->remote_port &&
3149 MyProcPort->remote_port[0] != '\0')
3150 appendStringInfo(buf, "(%s)",
3152 }
3153 }
3154 else if (padding != 0)
3156 padding > 0 ? padding : -padding);
3157 break;
3158 case 'h':
3160 {
3161 if (padding != 0)
3162 appendStringInfo(buf, "%*s", padding, MyProcPort->remote_host);
3163 else
3165 }
3166 else if (padding != 0)
3168 padding > 0 ? padding : -padding);
3169 break;
3170 case 'q':
3171 /* in postmaster and friends, stop if %q is seen */
3172 /* in a backend, just ignore */
3173 if (MyProcPort == NULL)
3174 return;
3175 break;
3176 case 'v':
3177 /* keep VXID format in sync with lockfuncs.c */
3178 if (MyProc != NULL && MyProc->vxid.procNumber != INVALID_PROC_NUMBER)
3179 {
3180 if (padding != 0)
3181 {
3182 char strfbuf[128];
3183
3184 snprintf(strfbuf, sizeof(strfbuf) - 1, "%d/%u",
3186 appendStringInfo(buf, "%*s", padding, strfbuf);
3187 }
3188 else
3190 }
3191 else if (padding != 0)
3193 padding > 0 ? padding : -padding);
3194 break;
3195 case 'x':
3196 if (padding != 0)
3197 appendStringInfo(buf, "%*u", padding, GetTopTransactionIdIfAny());
3198 else
3200 break;
3201 case 'e':
3202 if (padding != 0)
3203 appendStringInfo(buf, "%*s", padding, unpack_sql_state(edata->sqlerrcode));
3204 else
3206 break;
3207 case 'Q':
3208 if (padding != 0)
3209 appendStringInfo(buf, "%*" PRId64, padding,
3211 else
3212 appendStringInfo(buf, "%" PRId64,
3214 break;
3215 default:
3216 /* format error - ignore it */
3217 break;
3218 }
3219 }
3220}
uint64 pgstat_get_my_query_id(void)
#define INT64_HEX_FORMAT
Definition: c.h:522
static const char * process_log_prefix_padding(const char *p, int *ppadding)
Definition: elog.c:2802
char * get_formatted_start_time(void)
Definition: elog.c:2733
const char * get_backend_type_for_log(void)
Definition: elog.c:2780
char * get_formatted_log_time(void)
Definition: elog.c:2683
char * unpack_sql_state(int sql_state)
Definition: elog.c:3227
#define _(x)
Definition: elog.c:91
void reset_formatted_start_time(void)
Definition: elog.c:2721
struct Port * MyProcPort
Definition: globals.c:51
char * application_name
Definition: guc_tables.c:548
static char * username
Definition: initdb.c:153
int pg_getnameinfo_all(const struct sockaddr_storage *addr, int salen, char *node, int nodelen, char *service, int servicelen, int flags)
Definition: ip.c:114
static char format
static time_t start_time
Definition: pg_ctl.c:95
#define snprintf
Definition: port.h:239
#define INVALID_PROC_NUMBER
Definition: procnumber.h:26
const char * get_ps_display(int *displen)
Definition: ps_status.c:532
char * psprintf(const char *fmt,...)
Definition: psprintf.c:43
PGPROC * MyProc
Definition: proc.c:66
char * dbname
Definition: streamutil.c:49
void appendStringInfo(StringInfo str, const char *fmt,...)
Definition: stringinfo.c:145
void appendBinaryStringInfo(StringInfo str, const void *data, int datalen)
Definition: stringinfo.c:281
void appendStringInfoSpaces(StringInfo str, int count)
Definition: stringinfo.c:260
void appendStringInfoString(StringInfo str, const char *s)
Definition: stringinfo.c:230
void appendStringInfoChar(StringInfo str, char ch)
Definition: stringinfo.c:242
Definition: proc.h:163
struct PGPROC::@127 vxid
LocalTransactionId lxid
Definition: proc.h:201
ProcNumber procNumber
Definition: proc.h:196
int pid
Definition: proc.h:183
PGPROC * lockGroupLeader
Definition: proc.h:305
char * user_name
Definition: libpq-be.h:151
char * remote_port
Definition: libpq-be.h:140
SockAddr laddr
Definition: libpq-be.h:133
char * database_name
Definition: libpq-be.h:150
char * remote_host
Definition: libpq-be.h:135
char local_host[64]
Definition: libpq-be.h:143
struct sockaddr_storage addr
Definition: pqcomm.h:32
socklen_t salen
Definition: pqcomm.h:33
TransactionId GetTopTransactionIdIfAny(void)
Definition: xact.c:441

References _, SockAddr::addr, appendBinaryStringInfo(), appendStringInfo(), appendStringInfoChar(), appendStringInfoSpaces(), appendStringInfoString(), application_name, buf, Port::database_name, dbname, format, formatted_log_time, get_backend_type_for_log(), get_formatted_log_time(), get_formatted_start_time(), get_ps_display(), gettimeofday(), GetTopTransactionIdIfAny(), INT64_HEX_FORMAT, INVALID_PROC_NUMBER, Port::laddr, Port::local_host, PGPROC::lockGroupLeader, log_timezone, PGPROC::lxid, MyProc, MyProcPid, MyProcPort, MyStartTime, pfree(), pg_getnameinfo_all(), pg_localtime(), pg_strftime(), pgstat_get_my_query_id(), PGPROC::pid, process_log_prefix_padding(), PGPROC::procNumber, psprintf(), Port::remote_host, Port::remote_port, reset_formatted_start_time(), SockAddr::salen, saved_timeval, saved_timeval_set, snprintf, ErrorData::sqlerrcode, start_time, unpack_sql_state(), Port::user_name, username, and PGPROC::vxid.

Referenced by log_line_prefix().

◆ matches_backtrace_functions()

static bool matches_backtrace_functions ( const char *  funcname)
static

Definition at line 826 of file elog.c.

827{
828 const char *p;
829
830 if (!backtrace_function_list || funcname == NULL || funcname[0] == '\0')
831 return false;
832
834 for (;;)
835 {
836 if (*p == '\0') /* end of backtrace_function_list */
837 break;
838
839 if (strcmp(funcname, p) == 0)
840 return true;
841 p += strlen(p) + 1;
842 }
843
844 return false;
845}

References backtrace_function_list, and funcname.

Referenced by errfinish().

◆ message_level_is_interesting()

bool message_level_is_interesting ( int  elevel)

Definition at line 273 of file elog.c.

274{
275 /*
276 * Keep this in sync with the decision-making in errstart().
277 */
278 if (elevel >= ERROR ||
279 should_output_to_server(elevel) ||
281 return true;
282 return false;
283}

References ERROR, should_output_to_client(), and should_output_to_server().

Referenced by log_invalid_page(), PostmasterMain(), ProcessStandbyHSFeedbackMessage(), ProcessStandbyReplyMessage(), ProcessWalSndrMessage(), ProcSleep(), reportDependentObjects(), ShowTransactionState(), and VacuumUpdateCosts().

◆ pg_re_throw()

void pg_re_throw ( void  )

Definition at line 2026 of file elog.c.

2027{
2028 /* If possible, throw the error to the next outer setjmp handler */
2029 if (PG_exception_stack != NULL)
2030 siglongjmp(*PG_exception_stack, 1);
2031 else
2032 {
2033 /*
2034 * If we get here, elog(ERROR) was thrown inside a PG_TRY block, which
2035 * we have now exited only to discover that there is no outer setjmp
2036 * handler to pass the error to. Had the error been thrown outside
2037 * the block to begin with, we'd have promoted the error to FATAL, so
2038 * the correct behavior is to make it FATAL now; that is, emit it and
2039 * then call proc_exit.
2040 */
2042
2044 Assert(edata->elevel == ERROR);
2045 edata->elevel = FATAL;
2046
2047 /*
2048 * At least in principle, the increase in severity could have changed
2049 * where-to-output decisions, so recalculate.
2050 */
2053
2054 /*
2055 * We can use errfinish() for the rest, but we don't want it to call
2056 * any error context routines a second time. Since we know we are
2057 * about to exit, it should be OK to just clear the context stack.
2058 */
2059 error_context_stack = NULL;
2060
2061 errfinish(edata->filename, edata->lineno, edata->funcname);
2062 }
2063
2064 /* Doesn't return ... */
2065 ExceptionalCondition("pg_re_throw tried to return", __FILE__, __LINE__);
2066}
void ExceptionalCondition(const char *conditionName, const char *fileName, int lineNumber)
Definition: assert.c:30
int lineno
Definition: elog.h:427

References Assert(), ErrorData::elevel, errfinish(), ERROR, error_context_stack, errordata, errordata_stack_depth, ExceptionalCondition(), FATAL, ErrorData::filename, ErrorData::funcname, ErrorData::lineno, ErrorData::output_to_client, ErrorData::output_to_server, PG_exception_stack, should_output_to_client(), and should_output_to_server().

◆ pre_format_elog_string()

void pre_format_elog_string ( int  errnumber,
const char *  domain 
)

Definition at line 1667 of file elog.c.

1668{
1669 /* Save errno before evaluation of argument functions can change it */
1670 save_format_errnumber = errnumber;
1671 /* Save caller's text domain */
1672 save_format_domain = domain;
1673}

References save_format_domain, and save_format_errnumber.

◆ process_log_prefix_padding()

static const char * process_log_prefix_padding ( const char *  p,
int *  ppadding 
)
static

Definition at line 2802 of file elog.c.

2803{
2804 int paddingsign = 1;
2805 int padding = 0;
2806
2807 if (*p == '-')
2808 {
2809 p++;
2810
2811 if (*p == '\0') /* Did the buf end in %- ? */
2812 return NULL;
2813 paddingsign = -1;
2814 }
2815
2816 /* generate an int version of the numerical string */
2817 while (*p >= '0' && *p <= '9')
2818 padding = padding * 10 + (*p++ - '0');
2819
2820 /* format is invalid if it ends with the padding number */
2821 if (*p == '\0')
2822 return NULL;
2823
2824 padding *= paddingsign;
2825 *ppadding = padding;
2826 return p;
2827}

Referenced by log_status_format().

◆ reset_formatted_start_time()

void reset_formatted_start_time ( void  )

Definition at line 2721 of file elog.c.

2722{
2723 formatted_start_time[0] = '\0';
2724}

References formatted_start_time.

Referenced by log_status_format(), write_csvlog(), and write_jsonlog().

◆ ReThrowError()

void ReThrowError ( ErrorData edata)

Definition at line 1976 of file elog.c.

1977{
1978 ErrorData *newedata;
1979
1980 Assert(edata->elevel == ERROR);
1981
1982 /* Push the data back into the error context */
1985
1986 newedata = get_error_stack_entry();
1987 memcpy(newedata, edata, sizeof(ErrorData));
1988
1989 /* Make copies of separately-allocated fields */
1990 if (newedata->message)
1991 newedata->message = pstrdup(newedata->message);
1992 if (newedata->detail)
1993 newedata->detail = pstrdup(newedata->detail);
1994 if (newedata->detail_log)
1995 newedata->detail_log = pstrdup(newedata->detail_log);
1996 if (newedata->hint)
1997 newedata->hint = pstrdup(newedata->hint);
1998 if (newedata->context)
1999 newedata->context = pstrdup(newedata->context);
2000 if (newedata->backtrace)
2001 newedata->backtrace = pstrdup(newedata->backtrace);
2002 if (newedata->schema_name)
2003 newedata->schema_name = pstrdup(newedata->schema_name);
2004 if (newedata->table_name)
2005 newedata->table_name = pstrdup(newedata->table_name);
2006 if (newedata->column_name)
2007 newedata->column_name = pstrdup(newedata->column_name);
2008 if (newedata->datatype_name)
2009 newedata->datatype_name = pstrdup(newedata->datatype_name);
2010 if (newedata->constraint_name)
2011 newedata->constraint_name = pstrdup(newedata->constraint_name);
2012 if (newedata->internalquery)
2013 newedata->internalquery = pstrdup(newedata->internalquery);
2014
2015 /* Reset the assoc_context to be ErrorContext */
2016 newedata->assoc_context = ErrorContext;
2017
2019 PG_RE_THROW();
2020}

References Assert(), ErrorData::assoc_context, ErrorData::backtrace, ErrorData::column_name, ErrorData::constraint_name, ErrorData::context, ErrorData::datatype_name, ErrorData::detail, ErrorData::detail_log, ErrorData::elevel, ERROR, ErrorContext, get_error_stack_entry(), ErrorData::hint, ErrorData::internalquery, MemoryContextSwitchTo(), ErrorData::message, PG_RE_THROW, pstrdup(), recursion_depth, ErrorData::schema_name, and ErrorData::table_name.

Referenced by _SPI_commit(), _SPI_rollback(), exec_stmt_block(), and exec_stmt_raise().

◆ send_message_to_frontend()

static void send_message_to_frontend ( ErrorData edata)
static

Definition at line 3550 of file elog.c.

3551{
3552 StringInfoData msgbuf;
3553
3554 /*
3555 * We no longer support pre-3.0 FE/BE protocol, except here. If a client
3556 * tries to connect using an older protocol version, it's nice to send the
3557 * "protocol version not supported" error in a format the client
3558 * understands. If protocol hasn't been set yet, early in backend
3559 * startup, assume modern protocol.
3560 */
3562 {
3563 /* New style with separate fields */
3564 const char *sev;
3565 char tbuf[12];
3566
3567 /* 'N' (Notice) is for nonfatal conditions, 'E' is for errors */
3568 if (edata->elevel < ERROR)
3570 else
3572
3573 sev = error_severity(edata->elevel);
3574 pq_sendbyte(&msgbuf, PG_DIAG_SEVERITY);
3575 err_sendstring(&msgbuf, _(sev));
3577 err_sendstring(&msgbuf, sev);
3578
3579 pq_sendbyte(&msgbuf, PG_DIAG_SQLSTATE);
3580 err_sendstring(&msgbuf, unpack_sql_state(edata->sqlerrcode));
3581
3582 /* M field is required per protocol, so always send something */
3584 if (edata->message)
3585 err_sendstring(&msgbuf, edata->message);
3586 else
3587 err_sendstring(&msgbuf, _("missing error text"));
3588
3589 if (edata->detail)
3590 {
3592 err_sendstring(&msgbuf, edata->detail);
3593 }
3594
3595 /* detail_log is intentionally not used here */
3596
3597 if (edata->hint)
3598 {
3600 err_sendstring(&msgbuf, edata->hint);
3601 }
3602
3603 if (edata->context)
3604 {
3605 pq_sendbyte(&msgbuf, PG_DIAG_CONTEXT);
3606 err_sendstring(&msgbuf, edata->context);
3607 }
3608
3609 if (edata->schema_name)
3610 {
3612 err_sendstring(&msgbuf, edata->schema_name);
3613 }
3614
3615 if (edata->table_name)
3616 {
3618 err_sendstring(&msgbuf, edata->table_name);
3619 }
3620
3621 if (edata->column_name)
3622 {
3624 err_sendstring(&msgbuf, edata->column_name);
3625 }
3626
3627 if (edata->datatype_name)
3628 {
3630 err_sendstring(&msgbuf, edata->datatype_name);
3631 }
3632
3633 if (edata->constraint_name)
3634 {
3636 err_sendstring(&msgbuf, edata->constraint_name);
3637 }
3638
3639 if (edata->cursorpos > 0)
3640 {
3641 snprintf(tbuf, sizeof(tbuf), "%d", edata->cursorpos);
3643 err_sendstring(&msgbuf, tbuf);
3644 }
3645
3646 if (edata->internalpos > 0)
3647 {
3648 snprintf(tbuf, sizeof(tbuf), "%d", edata->internalpos);
3650 err_sendstring(&msgbuf, tbuf);
3651 }
3652
3653 if (edata->internalquery)
3654 {
3656 err_sendstring(&msgbuf, edata->internalquery);
3657 }
3658
3659 if (edata->filename)
3660 {
3662 err_sendstring(&msgbuf, edata->filename);
3663 }
3664
3665 if (edata->lineno > 0)
3666 {
3667 snprintf(tbuf, sizeof(tbuf), "%d", edata->lineno);
3669 err_sendstring(&msgbuf, tbuf);
3670 }
3671
3672 if (edata->funcname)
3673 {
3675 err_sendstring(&msgbuf, edata->funcname);
3676 }
3677
3678 pq_sendbyte(&msgbuf, '\0'); /* terminator */
3679
3680 pq_endmessage(&msgbuf);
3681 }
3682 else
3683 {
3684 /* Old style --- gin up a backwards-compatible message */
3686
3688
3689 appendStringInfo(&buf, "%s: ", _(error_severity(edata->elevel)));
3690
3691 if (edata->message)
3693 else
3694 appendStringInfoString(&buf, _("missing error text"));
3695
3696 appendStringInfoChar(&buf, '\n');
3697
3698 /* 'N' (Notice) is for nonfatal conditions, 'E' is for errors */
3699 pq_putmessage_v2((edata->elevel < ERROR) ? 'N' : 'E', buf.data, buf.len + 1);
3700
3701 pfree(buf.data);
3702 }
3703
3704 /*
3705 * This flush is normally not necessary, since postgres.c will flush out
3706 * waiting data when control returns to the main loop. But it seems best
3707 * to leave it here, so that the client has some clue what happened if the
3708 * backend dies before getting back to the main loop ... error/notice
3709 * messages should not be a performance-critical path anyway, so an extra
3710 * flush won't hurt much ...
3711 */
3712 pq_flush();
3713}
static void err_sendstring(StringInfo buf, const char *str)
Definition: elog.c:3538
const char * error_severity(int elevel)
Definition: elog.c:3728
ProtocolVersion FrontendProtocol
Definition: globals.c:30
#define pq_flush()
Definition: libpq.h:46
#define PG_DIAG_INTERNAL_QUERY
Definition: postgres_ext.h:58
#define PG_DIAG_SOURCE_LINE
Definition: postgres_ext.h:66
#define PG_DIAG_STATEMENT_POSITION
Definition: postgres_ext.h:56
#define PG_DIAG_SOURCE_FILE
Definition: postgres_ext.h:65
#define PG_DIAG_MESSAGE_HINT
Definition: postgres_ext.h:55
#define PG_DIAG_SQLSTATE
Definition: postgres_ext.h:52
#define PG_DIAG_SEVERITY_NONLOCALIZED
Definition: postgres_ext.h:51
#define PG_DIAG_MESSAGE_PRIMARY
Definition: postgres_ext.h:53
#define PG_DIAG_MESSAGE_DETAIL
Definition: postgres_ext.h:54
#define PG_DIAG_CONTEXT
Definition: postgres_ext.h:59
#define PG_DIAG_SEVERITY
Definition: postgres_ext.h:50
#define PG_DIAG_SOURCE_FUNCTION
Definition: postgres_ext.h:67
#define PG_DIAG_INTERNAL_POSITION
Definition: postgres_ext.h:57
int pq_putmessage_v2(char msgtype, const char *s, size_t len)
Definition: pqcomm.c:1562
#define PG_PROTOCOL_MAJOR(v)
Definition: pqcomm.h:87
void pq_endmessage(StringInfo buf)
Definition: pqformat.c:296
void pq_beginmessage(StringInfo buf, char msgtype)
Definition: pqformat.c:88
static void pq_sendbyte(StringInfo buf, uint8 byt)
Definition: pqformat.h:160
#define PqMsg_ErrorResponse
Definition: protocol.h:44
#define PqMsg_NoticeResponse
Definition: protocol.h:49
void initStringInfo(StringInfo str)
Definition: stringinfo.c:97

References _, appendStringInfo(), appendStringInfoChar(), appendStringInfoString(), buf, ErrorData::column_name, ErrorData::constraint_name, ErrorData::context, ErrorData::cursorpos, ErrorData::datatype_name, ErrorData::detail, ErrorData::elevel, err_sendstring(), ERROR, error_severity(), ErrorData::filename, FrontendProtocol, ErrorData::funcname, ErrorData::hint, initStringInfo(), ErrorData::internalpos, ErrorData::internalquery, ErrorData::lineno, ErrorData::message, pfree(), PG_DIAG_COLUMN_NAME, PG_DIAG_CONSTRAINT_NAME, PG_DIAG_CONTEXT, PG_DIAG_DATATYPE_NAME, PG_DIAG_INTERNAL_POSITION, PG_DIAG_INTERNAL_QUERY, PG_DIAG_MESSAGE_DETAIL, PG_DIAG_MESSAGE_HINT, PG_DIAG_MESSAGE_PRIMARY, PG_DIAG_SCHEMA_NAME, PG_DIAG_SEVERITY, PG_DIAG_SEVERITY_NONLOCALIZED, PG_DIAG_SOURCE_FILE, PG_DIAG_SOURCE_FUNCTION, PG_DIAG_SOURCE_LINE, PG_DIAG_SQLSTATE, PG_DIAG_STATEMENT_POSITION, PG_DIAG_TABLE_NAME, PG_PROTOCOL_MAJOR, pq_beginmessage(), pq_endmessage(), pq_flush, pq_putmessage_v2(), pq_sendbyte(), PqMsg_ErrorResponse, PqMsg_NoticeResponse, ErrorData::schema_name, snprintf, ErrorData::sqlerrcode, ErrorData::table_name, and unpack_sql_state().

Referenced by EmitErrorReport().

◆ send_message_to_server_log()

static void send_message_to_server_log ( ErrorData edata)
static

Definition at line 3247 of file elog.c.

3248{
3250 bool fallback_to_stderr = false;
3251
3253
3254 log_line_prefix(&buf, edata);
3255 appendStringInfo(&buf, "%s: ", _(error_severity(edata->elevel)));
3256
3259
3260 if (edata->message)
3261 append_with_tabs(&buf, edata->message);
3262 else
3263 append_with_tabs(&buf, _("missing error text"));
3264
3265 if (edata->cursorpos > 0)
3266 appendStringInfo(&buf, _(" at character %d"),
3267 edata->cursorpos);
3268 else if (edata->internalpos > 0)
3269 appendStringInfo(&buf, _(" at character %d"),
3270 edata->internalpos);
3271
3272 appendStringInfoChar(&buf, '\n');
3273
3275 {
3276 if (edata->detail_log)
3277 {
3278 log_line_prefix(&buf, edata);
3279 appendStringInfoString(&buf, _("DETAIL: "));
3281 appendStringInfoChar(&buf, '\n');
3282 }
3283 else if (edata->detail)
3284 {
3285 log_line_prefix(&buf, edata);
3286 appendStringInfoString(&buf, _("DETAIL: "));
3287 append_with_tabs(&buf, edata->detail);
3288 appendStringInfoChar(&buf, '\n');
3289 }
3290 if (edata->hint)
3291 {
3292 log_line_prefix(&buf, edata);
3293 appendStringInfoString(&buf, _("HINT: "));
3294 append_with_tabs(&buf, edata->hint);
3295 appendStringInfoChar(&buf, '\n');
3296 }
3297 if (edata->internalquery)
3298 {
3299 log_line_prefix(&buf, edata);
3300 appendStringInfoString(&buf, _("QUERY: "));
3302 appendStringInfoChar(&buf, '\n');
3303 }
3304 if (edata->context && !edata->hide_ctx)
3305 {
3306 log_line_prefix(&buf, edata);
3307 appendStringInfoString(&buf, _("CONTEXT: "));
3308 append_with_tabs(&buf, edata->context);
3309 appendStringInfoChar(&buf, '\n');
3310 }
3312 {
3313 /* assume no newlines in funcname or filename... */
3314 if (edata->funcname && edata->filename)
3315 {
3316 log_line_prefix(&buf, edata);
3317 appendStringInfo(&buf, _("LOCATION: %s, %s:%d\n"),
3318 edata->funcname, edata->filename,
3319 edata->lineno);
3320 }
3321 else if (edata->filename)
3322 {
3323 log_line_prefix(&buf, edata);
3324 appendStringInfo(&buf, _("LOCATION: %s:%d\n"),
3325 edata->filename, edata->lineno);
3326 }
3327 }
3328 if (edata->backtrace)
3329 {
3330 log_line_prefix(&buf, edata);
3331 appendStringInfoString(&buf, _("BACKTRACE: "));
3332 append_with_tabs(&buf, edata->backtrace);
3333 appendStringInfoChar(&buf, '\n');
3334 }
3335 }
3336
3337 /*
3338 * If the user wants the query that generated this error logged, do it.
3339 */
3340 if (check_log_of_query(edata))
3341 {
3342 log_line_prefix(&buf, edata);
3343 appendStringInfoString(&buf, _("STATEMENT: "));
3345 appendStringInfoChar(&buf, '\n');
3346 }
3347
3348#ifdef HAVE_SYSLOG
3349 /* Write to syslog, if enabled */
3351 {
3352 int syslog_level;
3353
3354 switch (edata->elevel)
3355 {
3356 case DEBUG5:
3357 case DEBUG4:
3358 case DEBUG3:
3359 case DEBUG2:
3360 case DEBUG1:
3361 syslog_level = LOG_DEBUG;
3362 break;
3363 case LOG:
3364 case LOG_SERVER_ONLY:
3365 case INFO:
3366 syslog_level = LOG_INFO;
3367 break;
3368 case NOTICE:
3369 case WARNING:
3371 syslog_level = LOG_NOTICE;
3372 break;
3373 case ERROR:
3374 syslog_level = LOG_WARNING;
3375 break;
3376 case FATAL:
3377 syslog_level = LOG_ERR;
3378 break;
3379 case PANIC:
3380 default:
3381 syslog_level = LOG_CRIT;
3382 break;
3383 }
3384
3385 write_syslog(syslog_level, buf.data);
3386 }
3387#endif /* HAVE_SYSLOG */
3388
3389#ifdef WIN32
3390 /* Write to eventlog, if enabled */
3392 {
3393 write_eventlog(edata->elevel, buf.data, buf.len);
3394 }
3395#endif /* WIN32 */
3396
3397 /* Write to csvlog, if enabled */
3399 {
3400 /*
3401 * Send CSV data if it's safe to do so (syslogger doesn't need the
3402 * pipe). If this is not possible, fallback to an entry written to
3403 * stderr.
3404 */
3406 write_csvlog(edata);
3407 else
3408 fallback_to_stderr = true;
3409 }
3410
3411 /* Write to JSON log, if enabled */
3413 {
3414 /*
3415 * Send JSON data if it's safe to do so (syslogger doesn't need the
3416 * pipe). If this is not possible, fallback to an entry written to
3417 * stderr.
3418 */
3420 {
3421 write_jsonlog(edata);
3422 }
3423 else
3424 fallback_to_stderr = true;
3425 }
3426
3427 /*
3428 * Write to stderr, if enabled or if required because of a previous
3429 * limitation.
3430 */
3433 fallback_to_stderr)
3434 {
3435 /*
3436 * Use the chunking protocol if we know the syslogger should be
3437 * catching stderr output, and we are not ourselves the syslogger.
3438 * Otherwise, just do a vanilla write to stderr.
3439 */
3442#ifdef WIN32
3443
3444 /*
3445 * In a win32 service environment, there is no usable stderr. Capture
3446 * anything going there and write it to the eventlog instead.
3447 *
3448 * If stderr redirection is active, it was OK to write to stderr above
3449 * because that's really a pipe to the syslogger process.
3450 */
3451 else if (pgwin32_is_service())
3452 write_eventlog(edata->elevel, buf.data, buf.len);
3453#endif
3454 else
3455 write_console(buf.data, buf.len);
3456 }
3457
3458 /* If in the syslogger process, try to write messages direct to file */
3459 if (MyBackendType == B_LOGGER)
3461
3462 /* No more need of the message formatted for stderr */
3463 pfree(buf.data);
3464}
void write_csvlog(ErrorData *edata)
Definition: csvlog.c:63
@ DestDebug
Definition: dest.h:88
static void log_line_prefix(StringInfo buf, ErrorData *edata)
Definition: elog.c:2833
bool check_log_of_query(ErrorData *edata)
Definition: elog.c:2757
static void append_with_tabs(StringInfo buf, const char *str)
Definition: elog.c:3780
int Log_error_verbosity
Definition: elog.c:109
void write_pipe_chunks(char *data, int len, int dest)
Definition: elog.c:3487
static void write_console(const char *line, int len)
Definition: elog.c:2605
@ PGERROR_VERBOSE
Definition: elog.h:474
@ PGERROR_DEFAULT
Definition: elog.h:473
void write_jsonlog(ErrorData *edata)
Definition: jsonlog.c:109
@ B_LOGGER
Definition: miscadmin.h:373
bool redirection_done
Definition: postmaster.c:375
void write_syslogger_file(const char *buffer, int count, int destination)
Definition: syslogger.c:1093
int pgwin32_is_service(void)

References _, append_with_tabs(), appendStringInfo(), appendStringInfoChar(), appendStringInfoString(), B_LOGGER, ErrorData::backtrace, buf, check_log_of_query(), ErrorData::context, ErrorData::cursorpos, DEBUG1, DEBUG2, DEBUG3, DEBUG4, DEBUG5, debug_query_string, DestDebug, ErrorData::detail, ErrorData::detail_log, ErrorData::elevel, ERROR, error_severity(), FATAL, ErrorData::filename, ErrorData::funcname, ErrorData::hide_ctx, ErrorData::hint, INFO, initStringInfo(), ErrorData::internalpos, ErrorData::internalquery, ErrorData::lineno, LOG, Log_destination, LOG_DESTINATION_CSVLOG, LOG_DESTINATION_EVENTLOG, LOG_DESTINATION_JSONLOG, LOG_DESTINATION_STDERR, LOG_DESTINATION_SYSLOG, Log_error_verbosity, log_line_prefix(), LOG_SERVER_ONLY, ErrorData::message, MyBackendType, NOTICE, PANIC, pfree(), PGERROR_DEFAULT, PGERROR_VERBOSE, pgwin32_is_service(), redirection_done, ErrorData::sqlerrcode, unpack_sql_state(), WARNING, WARNING_CLIENT_ONLY, whereToSendOutput, write_console(), write_csvlog(), write_jsonlog(), write_pipe_chunks(), and write_syslogger_file().

Referenced by EmitErrorReport().

◆ set_backtrace()

static void set_backtrace ( ErrorData edata,
int  num_skip 
)
static

Definition at line 1117 of file elog.c.

1118{
1119 StringInfoData errtrace;
1120
1121 initStringInfo(&errtrace);
1122
1123#ifdef HAVE_BACKTRACE_SYMBOLS
1124 {
1125 void *buf[100];
1126 int nframes;
1127 char **strfrms;
1128
1129 nframes = backtrace(buf, lengthof(buf));
1130 strfrms = backtrace_symbols(buf, nframes);
1131 if (strfrms == NULL)
1132 return;
1133
1134 for (int i = num_skip; i < nframes; i++)
1135 appendStringInfo(&errtrace, "\n%s", strfrms[i]);
1136 free(strfrms);
1137 }
1138#else
1139 appendStringInfoString(&errtrace,
1140 "backtrace generation is not supported by this installation");
1141#endif
1142
1143 edata->backtrace = errtrace.data;
1144}
#define lengthof(array)
Definition: c.h:759

References appendStringInfo(), appendStringInfoString(), ErrorData::backtrace, buf, StringInfoData::data, free, i, initStringInfo(), and lengthof.

Referenced by errbacktrace(), and errfinish().

◆ set_errcontext_domain()

int set_errcontext_domain ( const char *  domain)

Definition at line 1413 of file elog.c.

1414{
1416
1417 /* we don't bother incrementing recursion_depth */
1419
1420 /* the default text domain is the backend's */
1421 edata->context_domain = domain ? domain : PG_TEXTDOMAIN("postgres");
1422
1423 return 0; /* return value does not matter */
1424}

References CHECK_STACK_DEPTH, ErrorData::context_domain, errordata, errordata_stack_depth, and PG_TEXTDOMAIN.

◆ set_errdata_field()

static void set_errdata_field ( MemoryContextData cxt,
char **  ptr,
const char *  str 
)
static

Definition at line 1570 of file elog.c.

1571{
1572 Assert(*ptr == NULL);
1573 *ptr = MemoryContextStrdup(cxt, str);
1574}

References Assert(), MemoryContextStrdup(), and str.

Referenced by err_generic_string().

◆ set_stack_entry_domain()

static void set_stack_entry_domain ( ErrorData edata,
const char *  domain 
)
static

Definition at line 779 of file elog.c.

780{
781 /* the default text domain is the backend's */
782 edata->domain = domain ? domain : PG_TEXTDOMAIN("postgres");
783 /* initialize context_domain the same way (see set_errcontext_domain()) */
784 edata->context_domain = edata->domain;
785}

References ErrorData::context_domain, ErrorData::domain, and PG_TEXTDOMAIN.

Referenced by errsave_start(), and errstart().

◆ set_stack_entry_location()

static void set_stack_entry_location ( ErrorData edata,
const char *  filename,
int  lineno,
const char *  funcname 
)
static

Definition at line 796 of file elog.c.

799{
800 if (filename)
801 {
802 const char *slash;
803
804 /* keep only base name, useful especially for vpath builds */
805 slash = strrchr(filename, '/');
806 if (slash)
807 filename = slash + 1;
808 /* Some Windows compilers use backslashes in __FILE__ strings */
809 slash = strrchr(filename, '\\');
810 if (slash)
811 filename = slash + 1;
812 }
813
814 edata->filename = filename;
815 edata->lineno = lineno;
816 edata->funcname = funcname;
817}

References filename, ErrorData::filename, ErrorData::funcname, funcname, and ErrorData::lineno.

Referenced by errfinish(), and errsave_finish().

◆ should_output_to_client()

static bool should_output_to_client ( int  elevel)
inlinestatic

Definition at line 245 of file elog.c.

246{
247 if (whereToSendOutput == DestRemote && elevel != LOG_SERVER_ONLY)
248 {
249 /*
250 * client_min_messages is honored only after we complete the
251 * authentication handshake. This is required both for security
252 * reasons and because many clients can't handle NOTICE messages
253 * during authentication.
254 */
256 return (elevel >= ERROR);
257 else
258 return (elevel >= client_min_messages || elevel == INFO);
259 }
260 return false;
261}
int client_min_messages
Definition: guc_tables.c:528
bool ClientAuthInProgress
Definition: postmaster.c:372

References client_min_messages, ClientAuthInProgress, DestRemote, ERROR, INFO, LOG_SERVER_ONLY, and whereToSendOutput.

Referenced by errstart(), message_level_is_interesting(), and pg_re_throw().

◆ should_output_to_server()

static bool should_output_to_server ( int  elevel)
inlinestatic

Definition at line 236 of file elog.c.

237{
239}
int log_min_messages
Definition: guc_tables.c:527

References is_log_level_output(), and log_min_messages.

Referenced by errstart(), message_level_is_interesting(), and pg_re_throw().

◆ ThrowErrorData()

void ThrowErrorData ( ErrorData edata)

Definition at line 1917 of file elog.c.

1918{
1919 ErrorData *newedata;
1920 MemoryContext oldcontext;
1921
1922 if (!errstart(edata->elevel, edata->domain))
1923 return; /* error is not to be reported at all */
1924
1925 newedata = &errordata[errordata_stack_depth];
1927 oldcontext = MemoryContextSwitchTo(newedata->assoc_context);
1928
1929 /* Copy the supplied fields to the error stack entry. */
1930 if (edata->sqlerrcode != 0)
1931 newedata->sqlerrcode = edata->sqlerrcode;
1932 if (edata->message)
1933 newedata->message = pstrdup(edata->message);
1934 if (edata->detail)
1935 newedata->detail = pstrdup(edata->detail);
1936 if (edata->detail_log)
1937 newedata->detail_log = pstrdup(edata->detail_log);
1938 if (edata->hint)
1939 newedata->hint = pstrdup(edata->hint);
1940 if (edata->context)
1941 newedata->context = pstrdup(edata->context);
1942 if (edata->backtrace)
1943 newedata->backtrace = pstrdup(edata->backtrace);
1944 /* assume message_id is not available */
1945 if (edata->schema_name)
1946 newedata->schema_name = pstrdup(edata->schema_name);
1947 if (edata->table_name)
1948 newedata->table_name = pstrdup(edata->table_name);
1949 if (edata->column_name)
1950 newedata->column_name = pstrdup(edata->column_name);
1951 if (edata->datatype_name)
1952 newedata->datatype_name = pstrdup(edata->datatype_name);
1953 if (edata->constraint_name)
1954 newedata->constraint_name = pstrdup(edata->constraint_name);
1955 newedata->cursorpos = edata->cursorpos;
1956 newedata->internalpos = edata->internalpos;
1957 if (edata->internalquery)
1958 newedata->internalquery = pstrdup(edata->internalquery);
1959
1960 MemoryContextSwitchTo(oldcontext);
1962
1963 /* Process the error. */
1964 errfinish(edata->filename, edata->lineno, edata->funcname);
1965}

References ErrorData::assoc_context, ErrorData::backtrace, ErrorData::column_name, ErrorData::constraint_name, ErrorData::context, ErrorData::cursorpos, ErrorData::datatype_name, ErrorData::detail, ErrorData::detail_log, ErrorData::domain, ErrorData::elevel, errfinish(), errordata, errordata_stack_depth, errstart(), ErrorData::filename, ErrorData::funcname, ErrorData::hint, ErrorData::internalpos, ErrorData::internalquery, ErrorData::lineno, MemoryContextSwitchTo(), ErrorData::message, pstrdup(), recursion_depth, ErrorData::schema_name, ErrorData::sqlerrcode, and ErrorData::table_name.

Referenced by ProcessParallelMessage(), and text_to_stavalues().

◆ unpack_sql_state()

char * unpack_sql_state ( int  sql_state)

Definition at line 3227 of file elog.c.

3228{
3229 static char buf[12];
3230 int i;
3231
3232 for (i = 0; i < 5; i++)
3233 {
3234 buf[i] = PGUNSIXBIT(sql_state);
3235 sql_state >>= 6;
3236 }
3237
3238 buf[i] = '\0';
3239 return buf;
3240}
#define PGUNSIXBIT(val)
Definition: elog.h:54

References buf, i, and PGUNSIXBIT.

Referenced by exec_stmt_block(), exec_stmt_getdiag(), exec_stmt_raise(), log_status_format(), pg_input_error_info(), pltcl_construct_errorCode(), PLy_exception_set_with_details(), PLy_generate_spi_exceptions(), send_message_to_frontend(), send_message_to_server_log(), write_csvlog(), and write_jsonlog().

◆ write_console()

static void write_console ( const char *  line,
int  len 
)
static

Definition at line 2605 of file elog.c.

2606{
2607 int rc;
2608
2609#ifdef WIN32
2610
2611 /*
2612 * Try to convert the message to UTF16 and write it with WriteConsoleW().
2613 * Fall back on write() if anything fails.
2614 *
2615 * In contrast to write_eventlog(), don't skip straight to write() based
2616 * on the applicable encodings. Unlike WriteConsoleW(), write() depends
2617 * on the suitability of the console output code page. Since we put
2618 * stderr into binary mode in SubPostmasterMain(), write() skips the
2619 * necessary translation anyway.
2620 *
2621 * WriteConsoleW() will fail if stderr is redirected, so just fall through
2622 * to writing unconverted to the logfile in this case.
2623 *
2624 * Since we palloc the structure required for conversion, also fall
2625 * through to writing unconverted if we have not yet set up
2626 * CurrentMemoryContext.
2627 */
2630 CurrentMemoryContext != NULL)
2631 {
2632 WCHAR *utf16;
2633 int utf16len;
2634
2635 utf16 = pgwin32_message_to_UTF16(line, len, &utf16len);
2636 if (utf16 != NULL)
2637 {
2638 HANDLE stdHandle;
2639 DWORD written;
2640
2641 stdHandle = GetStdHandle(STD_ERROR_HANDLE);
2642 if (WriteConsoleW(stdHandle, utf16, utf16len, &written, NULL))
2643 {
2644 pfree(utf16);
2645 return;
2646 }
2647
2648 /*
2649 * In case WriteConsoleW() failed, fall back to writing the
2650 * message unconverted.
2651 */
2652 pfree(utf16);
2653 }
2654 }
2655#else
2656
2657 /*
2658 * Conversion on non-win32 platforms is not implemented yet. It requires
2659 * non-throw version of pg_do_encoding_conversion(), that converts
2660 * unconvertible characters to '?' without errors.
2661 *
2662 * XXX: We have a no-throw version now. It doesn't convert to '?' though.
2663 */
2664#endif
2665
2666 /*
2667 * We ignore any error from write() here. We have no useful way to report
2668 * it ... certainly whining on stderr isn't likely to be productive.
2669 */
2670 rc = write(fileno(stderr), line, len);
2671 (void) rc;
2672}
#define write(a, b, c)
Definition: win32.h:14
const void size_t len

References CurrentMemoryContext, in_error_recursion_trouble(), len, pfree(), redirection_done, and write.

Referenced by send_message_to_server_log(), and write_stderr().

◆ write_pipe_chunks()

void write_pipe_chunks ( char *  data,
int  len,
int  dest 
)

Definition at line 3487 of file elog.c.

3488{
3490 int fd = fileno(stderr);
3491 int rc;
3492
3493 Assert(len > 0);
3494
3495 p.proto.nuls[0] = p.proto.nuls[1] = '\0';
3496 p.proto.pid = MyProcPid;
3497 p.proto.flags = 0;
3500 else if (dest == LOG_DESTINATION_CSVLOG)
3502 else if (dest == LOG_DESTINATION_JSONLOG)
3504
3505 /* write all but the last chunk */
3506 while (len > PIPE_MAX_PAYLOAD)
3507 {
3508 /* no need to set PIPE_PROTO_IS_LAST yet */
3510 memcpy(p.proto.data, data, PIPE_MAX_PAYLOAD);
3512 (void) rc;
3515 }
3516
3517 /* write the last chunk */
3519 p.proto.len = len;
3520 memcpy(p.proto.data, data, len);
3521 rc = write(fd, &p, PIPE_HEADER_SIZE + len);
3522 (void) rc;
3523}
const void * data
char data[FLEXIBLE_ARRAY_MEMBER]
Definition: syslogger.h:50
char nuls[2]
Definition: syslogger.h:46
#define PIPE_PROTO_DEST_JSONLOG
Definition: syslogger.h:67
#define PIPE_PROTO_IS_LAST
Definition: syslogger.h:63
#define PIPE_PROTO_DEST_CSVLOG
Definition: syslogger.h:66
#define PIPE_PROTO_DEST_STDERR
Definition: syslogger.h:65
#define PIPE_MAX_PAYLOAD
Definition: syslogger.h:60
#define PIPE_HEADER_SIZE
Definition: syslogger.h:59
PipeProtoHeader proto
Definition: syslogger.h:55

References Assert(), PipeProtoHeader::data, data, generate_unaccent_rules::dest, fd(), PipeProtoHeader::flags, PipeProtoHeader::len, len, LOG_DESTINATION_CSVLOG, LOG_DESTINATION_JSONLOG, LOG_DESTINATION_STDERR, MyProcPid, PipeProtoHeader::nuls, PipeProtoHeader::pid, PIPE_HEADER_SIZE, PIPE_MAX_PAYLOAD, PIPE_PROTO_DEST_CSVLOG, PIPE_PROTO_DEST_JSONLOG, PIPE_PROTO_DEST_STDERR, PIPE_PROTO_IS_LAST, PipeProtoChunk::proto, and write.

Referenced by send_message_to_server_log(), write_csvlog(), and write_jsonlog().

◆ write_stderr()

static void write_stderr ( const char *  fmt,
  ... 
)

Definition at line 3799 of file elog.c.

3800{
3801 va_list ap;
3802
3803#ifdef WIN32
3804 char errbuf[2048]; /* Arbitrary size? */
3805#endif
3806
3807 fmt = _(fmt);
3808
3809 va_start(ap, fmt);
3810#ifndef WIN32
3811 /* On Unix, we just fprintf to stderr */
3812 vfprintf(stderr, fmt, ap);
3813 fflush(stderr);
3814#else
3815 vsnprintf(errbuf, sizeof(errbuf), fmt, ap);
3816
3817 /*
3818 * On Win32, we print to stderr if running on a console, or write to
3819 * eventlog if running as a service
3820 */
3821 if (pgwin32_is_service()) /* Running as a service */
3822 {
3823 write_eventlog(ERROR, errbuf, strlen(errbuf));
3824 }
3825 else
3826 {
3827 /* Not running as service, write to stderr */
3828 write_console(errbuf, strlen(errbuf));
3829 fflush(stderr);
3830 }
3831#endif
3832 va_end(ap);
3833}
#define vsnprintf
Definition: port.h:238
#define vfprintf
Definition: port.h:242

References _, ERROR, pgwin32_is_service(), vfprintf, vsnprintf, and write_console().

Referenced by errstart().

Variable Documentation

◆ backtrace_function_list

char* backtrace_function_list
static

Definition at line 117 of file elog.c.

Referenced by assign_backtrace_functions(), and matches_backtrace_functions().

◆ emit_log_hook

emit_log_hook_type emit_log_hook = NULL

Definition at line 106 of file elog.c.

Referenced by EmitErrorReport().

◆ error_context_stack

ErrorContextCallback* error_context_stack = NULL

Definition at line 95 of file elog.c.

Referenced by _SPI_execute_plan(), _SPI_prepare_oneshot_plan(), _SPI_prepare_plan(), ApplyWalRecord(), AutoVacLauncherMain(), AutoVacWorkerMain(), BackgroundWorkerMain(), BackgroundWriterMain(), begin_cb_wrapper(), begin_prepare_cb_wrapper(), call_pltcl_start_proc(), cancel_parser_errposition_callback(), cancel_scanner_errposition_callback(), change_cb_wrapper(), CheckpointerMain(), commit_cb_wrapper(), commit_prepared_cb_wrapper(), compile_plperl_function(), CopyFrom(), CreateParallelContext(), errfinish(), errstart(), exec_bind_message(), exec_execute_message(), execute_sql_string(), file_acquire_sample_rows(), fileIterateForeignScan(), filter_by_origin_cb_wrapper(), filter_prepare_cb_wrapper(), FlushBuffer(), FlushRelationBuffers(), fmgr_sql(), fmgr_sql_validator(), GetErrorContextStack(), heap_vacuum_rel(), ImportForeignSchema(), inline_function(), inline_set_returning_function(), IoWorkerMain(), LogicalParallelApplyLoop(), LogicalRepApplyLoop(), make_tuple_from_result_row(), message_cb_wrapper(), parallel_vacuum_main(), pg_re_throw(), pgarch_archiveXlog(), plperl_event_trigger_handler(), plperl_func_handler(), plperl_inline_handler(), plperl_trigger_handler(), plpgsql_compile_callback(), plpgsql_compile_inline(), plpgsql_exec_event_trigger(), plpgsql_exec_function(), plpgsql_exec_trigger(), plpython3_call_handler(), plpython3_inline_handler(), PLy_exec_function(), PLy_modify_tuple(), PostgresMain(), prepare_cb_wrapper(), proc_exit_prepare(), ProcessParallelApplyMessage(), ProcessParallelMessage(), quickdie(), ReindexPartitions(), ReplSlotSyncWorkerMain(), RestoreGUCState(), rollback_prepared_cb_wrapper(), setup_parser_errposition_callback(), setup_scanner_errposition_callback(), shutdown_cb_wrapper(), SPI_cursor_open_internal(), SPI_plan_get_cached_plan(), sql_compile_callback(), startup_cb_wrapper(), stream_abort_cb_wrapper(), stream_change_cb_wrapper(), stream_commit_cb_wrapper(), stream_message_cb_wrapper(), stream_prepare_cb_wrapper(), stream_start_cb_wrapper(), stream_stop_cb_wrapper(), stream_truncate_cb_wrapper(), tokenize_auth_file(), truncate_cb_wrapper(), tsearch_readline_begin(), tsearch_readline_end(), typeStringToTypeName(), update_progress_txn_cb_wrapper(), WalSummarizerMain(), WalWriterMain(), and XactLockTableWait().

◆ errordata

◆ errordata_stack_depth

◆ formatted_log_time

char formatted_log_time[FORMATTED_TS_LEN]
static

Definition at line 161 of file elog.c.

Referenced by EmitErrorReport(), get_formatted_log_time(), and log_status_format().

◆ formatted_start_time

char formatted_start_time[FORMATTED_TS_LEN]
static

Definition at line 160 of file elog.c.

Referenced by get_formatted_start_time(), and reset_formatted_start_time().

◆ Log_destination

◆ Log_destination_string

char* Log_destination_string = NULL

Definition at line 112 of file elog.c.

Referenced by PostmasterMain().

◆ Log_error_verbosity

int Log_error_verbosity = PGERROR_DEFAULT

Definition at line 109 of file elog.c.

Referenced by send_message_to_server_log(), write_csvlog(), and write_jsonlog().

◆ Log_line_prefix

char* Log_line_prefix = NULL

Definition at line 110 of file elog.c.

Referenced by log_line_prefix().

◆ PG_exception_stack

◆ recursion_depth

◆ save_format_domain

const char* save_format_domain
static

Definition at line 1664 of file elog.c.

Referenced by format_elog_string(), and pre_format_elog_string().

◆ save_format_errnumber

int save_format_errnumber
static

Definition at line 1663 of file elog.c.

Referenced by format_elog_string(), and pre_format_elog_string().

◆ saved_timeval

struct timeval saved_timeval
static

Definition at line 156 of file elog.c.

Referenced by get_formatted_log_time(), and log_status_format().

◆ saved_timeval_set

bool saved_timeval_set = false
static

Definition at line 157 of file elog.c.

Referenced by EmitErrorReport(), get_formatted_log_time(), and log_status_format().

◆ syslog_sequence_numbers

bool syslog_sequence_numbers = true

Definition at line 113 of file elog.c.

◆ syslog_split_messages

bool syslog_split_messages = true

Definition at line 114 of file elog.c.