PostgreSQL Source Code  git master
pl_handler.c
Go to the documentation of this file.
1 /*-------------------------------------------------------------------------
2  *
3  * pl_handler.c - Handler for the PL/pgSQL
4  * procedural language
5  *
6  * Portions Copyright (c) 1996-2019, PostgreSQL Global Development Group
7  * Portions Copyright (c) 1994, Regents of the University of California
8  *
9  *
10  * IDENTIFICATION
11  * src/pl/plpgsql/src/pl_handler.c
12  *
13  *-------------------------------------------------------------------------
14  */
15 
16 #include "postgres.h"
17 
18 #include "access/htup_details.h"
19 #include "catalog/pg_proc.h"
20 #include "catalog/pg_type.h"
21 #include "funcapi.h"
22 #include "miscadmin.h"
23 #include "plpgsql.h"
24 #include "utils/builtins.h"
25 #include "utils/guc.h"
26 #include "utils/lsyscache.h"
27 #include "utils/syscache.h"
28 #include "utils/varlena.h"
29 
30 static bool plpgsql_extra_checks_check_hook(char **newvalue, void **extra, GucSource source);
31 static void plpgsql_extra_warnings_assign_hook(const char *newvalue, void *extra);
32 static void plpgsql_extra_errors_assign_hook(const char *newvalue, void *extra);
33 
35 
36 /* Custom GUC variable */
38  {"error", PLPGSQL_RESOLVE_ERROR, false},
39  {"use_variable", PLPGSQL_RESOLVE_VARIABLE, false},
40  {"use_column", PLPGSQL_RESOLVE_COLUMN, false},
41  {NULL, 0, false}
42 };
43 
45 
47 
49 
54 
55 /* Hook for plugins */
57 
58 
59 static bool
60 plpgsql_extra_checks_check_hook(char **newvalue, void **extra, GucSource source)
61 {
62  char *rawstring;
63  List *elemlist;
64  ListCell *l;
65  int extrachecks = 0;
66  int *myextra;
67 
68  if (pg_strcasecmp(*newvalue, "all") == 0)
69  extrachecks = PLPGSQL_XCHECK_ALL;
70  else if (pg_strcasecmp(*newvalue, "none") == 0)
71  extrachecks = PLPGSQL_XCHECK_NONE;
72  else
73  {
74  /* Need a modifiable copy of string */
75  rawstring = pstrdup(*newvalue);
76 
77  /* Parse string into list of identifiers */
78  if (!SplitIdentifierString(rawstring, ',', &elemlist))
79  {
80  /* syntax error in list */
81  GUC_check_errdetail("List syntax is invalid.");
82  pfree(rawstring);
83  list_free(elemlist);
84  return false;
85  }
86 
87  foreach(l, elemlist)
88  {
89  char *tok = (char *) lfirst(l);
90 
91  if (pg_strcasecmp(tok, "shadowed_variables") == 0)
92  extrachecks |= PLPGSQL_XCHECK_SHADOWVAR;
93  else if (pg_strcasecmp(tok, "too_many_rows") == 0)
94  extrachecks |= PLPGSQL_XCHECK_TOOMANYROWS;
95  else if (pg_strcasecmp(tok, "strict_multi_assignment") == 0)
97  else if (pg_strcasecmp(tok, "all") == 0 || pg_strcasecmp(tok, "none") == 0)
98  {
99  GUC_check_errdetail("Key word \"%s\" cannot be combined with other key words.", tok);
100  pfree(rawstring);
101  list_free(elemlist);
102  return false;
103  }
104  else
105  {
106  GUC_check_errdetail("Unrecognized key word: \"%s\".", tok);
107  pfree(rawstring);
108  list_free(elemlist);
109  return false;
110  }
111  }
112 
113  pfree(rawstring);
114  list_free(elemlist);
115  }
116 
117  myextra = (int *) malloc(sizeof(int));
118  if (!myextra)
119  return false;
120  *myextra = extrachecks;
121  *extra = (void *) myextra;
122 
123  return true;
124 }
125 
126 static void
127 plpgsql_extra_warnings_assign_hook(const char *newvalue, void *extra)
128 {
129  plpgsql_extra_warnings = *((int *) extra);
130 }
131 
132 static void
133 plpgsql_extra_errors_assign_hook(const char *newvalue, void *extra)
134 {
135  plpgsql_extra_errors = *((int *) extra);
136 }
137 
138 
139 /*
140  * _PG_init() - library load-time initialization
141  *
142  * DO NOT make this static nor change its name!
143  */
144 void
145 _PG_init(void)
146 {
147  /* Be sure we do initialization only once (should be redundant now) */
148  static bool inited = false;
149 
150  if (inited)
151  return;
152 
154 
155  DefineCustomEnumVariable("plpgsql.variable_conflict",
156  gettext_noop("Sets handling of conflicts between PL/pgSQL variable names and table column names."),
157  NULL,
160  variable_conflict_options,
161  PGC_SUSET, 0,
162  NULL, NULL, NULL);
163 
164  DefineCustomBoolVariable("plpgsql.print_strict_params",
165  gettext_noop("Print information about parameters in the DETAIL part of the error messages generated on INTO ... STRICT failures."),
166  NULL,
168  false,
169  PGC_USERSET, 0,
170  NULL, NULL, NULL);
171 
172  DefineCustomBoolVariable("plpgsql.check_asserts",
173  gettext_noop("Perform checks given in ASSERT statements."),
174  NULL,
176  true,
177  PGC_USERSET, 0,
178  NULL, NULL, NULL);
179 
180  DefineCustomStringVariable("plpgsql.extra_warnings",
181  gettext_noop("List of programming constructs that should produce a warning."),
182  NULL,
184  "none",
188  NULL);
189 
190  DefineCustomStringVariable("plpgsql.extra_errors",
191  gettext_noop("List of programming constructs that should produce an error."),
192  NULL,
194  "none",
198  NULL);
199 
200  EmitWarningsOnPlaceholders("plpgsql");
201 
205 
206  /* Set up a rendezvous point with optional instrumentation plugin */
207  plpgsql_plugin_ptr = (PLpgSQL_plugin **) find_rendezvous_variable("PLpgSQL_plugin");
208 
209  inited = true;
210 }
211 
212 /* ----------
213  * plpgsql_call_handler
214  *
215  * The PostgreSQL function manager and trigger manager
216  * call this function for execution of PL/pgSQL procedures.
217  * ----------
218  */
220 
221 Datum
223 {
224  bool nonatomic;
225  PLpgSQL_function *func;
226  PLpgSQL_execstate *save_cur_estate;
227  Datum retval;
228  int rc;
229 
230  nonatomic = fcinfo->context &&
231  IsA(fcinfo->context, CallContext) &&
232  !castNode(CallContext, fcinfo->context)->atomic;
233 
234  /*
235  * Connect to SPI manager
236  */
237  if ((rc = SPI_connect_ext(nonatomic ? SPI_OPT_NONATOMIC : 0)) != SPI_OK_CONNECT)
238  elog(ERROR, "SPI_connect failed: %s", SPI_result_code_string(rc));
239 
240  /* Find or compile the function */
241  func = plpgsql_compile(fcinfo, false);
242 
243  /* Must save and restore prior value of cur_estate */
244  save_cur_estate = func->cur_estate;
245 
246  /* Mark the function as busy, so it can't be deleted from under us */
247  func->use_count++;
248 
249  PG_TRY();
250  {
251  /*
252  * Determine if called as function or trigger and call appropriate
253  * subhandler
254  */
255  if (CALLED_AS_TRIGGER(fcinfo))
257  (TriggerData *) fcinfo->context));
258  else if (CALLED_AS_EVENT_TRIGGER(fcinfo))
259  {
261  (EventTriggerData *) fcinfo->context);
262  retval = (Datum) 0;
263  }
264  else
265  retval = plpgsql_exec_function(func, fcinfo, NULL, !nonatomic);
266  }
267  PG_FINALLY();
268  {
269  /* Decrement use-count, restore cur_estate */
270  func->use_count--;
271  func->cur_estate = save_cur_estate;
272  }
273  PG_END_TRY();
274 
275  /*
276  * Disconnect from SPI manager
277  */
278  if ((rc = SPI_finish()) != SPI_OK_FINISH)
279  elog(ERROR, "SPI_finish failed: %s", SPI_result_code_string(rc));
280 
281  return retval;
282 }
283 
284 /* ----------
285  * plpgsql_inline_handler
286  *
287  * Called by PostgreSQL to execute an anonymous code block
288  * ----------
289  */
291 
292 Datum
294 {
295  LOCAL_FCINFO(fake_fcinfo, 0);
297  PLpgSQL_function *func;
298  FmgrInfo flinfo;
299  EState *simple_eval_estate;
300  Datum retval;
301  int rc;
302 
303  /*
304  * Connect to SPI manager
305  */
306  if ((rc = SPI_connect_ext(codeblock->atomic ? 0 : SPI_OPT_NONATOMIC)) != SPI_OK_CONNECT)
307  elog(ERROR, "SPI_connect failed: %s", SPI_result_code_string(rc));
308 
309  /* Compile the anonymous code block */
310  func = plpgsql_compile_inline(codeblock->source_text);
311 
312  /* Mark the function as busy, just pro forma */
313  func->use_count++;
314 
315  /*
316  * Set up a fake fcinfo with just enough info to satisfy
317  * plpgsql_exec_function(). In particular note that this sets things up
318  * with no arguments passed.
319  */
320  MemSet(fake_fcinfo, 0, SizeForFunctionCallInfo(0));
321  MemSet(&flinfo, 0, sizeof(flinfo));
322  fake_fcinfo->flinfo = &flinfo;
323  flinfo.fn_oid = InvalidOid;
324  flinfo.fn_mcxt = CurrentMemoryContext;
325 
326  /* Create a private EState for simple-expression execution */
327  simple_eval_estate = CreateExecutorState();
328 
329  /* And run the function */
330  PG_TRY();
331  {
332  retval = plpgsql_exec_function(func, fake_fcinfo, simple_eval_estate, codeblock->atomic);
333  }
334  PG_CATCH();
335  {
336  /*
337  * We need to clean up what would otherwise be long-lived resources
338  * accumulated by the failed DO block, principally cached plans for
339  * statements (which can be flushed with plpgsql_free_function_memory)
340  * and execution trees for simple expressions, which are in the
341  * private EState.
342  *
343  * Before releasing the private EState, we must clean up any
344  * simple_econtext_stack entries pointing into it, which we can do by
345  * invoking the subxact callback. (It will be called again later if
346  * some outer control level does a subtransaction abort, but no harm
347  * is done.) We cheat a bit knowing that plpgsql_subxact_cb does not
348  * pay attention to its parentSubid argument.
349  */
352  0, NULL);
353 
354  /* Clean up the private EState */
355  FreeExecutorState(simple_eval_estate);
356 
357  /* Function should now have no remaining use-counts ... */
358  func->use_count--;
359  Assert(func->use_count == 0);
360 
361  /* ... so we can free subsidiary storage */
363 
364  /* And propagate the error */
365  PG_RE_THROW();
366  }
367  PG_END_TRY();
368 
369  /* Clean up the private EState */
370  FreeExecutorState(simple_eval_estate);
371 
372  /* Function should now have no remaining use-counts ... */
373  func->use_count--;
374  Assert(func->use_count == 0);
375 
376  /* ... so we can free subsidiary storage */
378 
379  /*
380  * Disconnect from SPI manager
381  */
382  if ((rc = SPI_finish()) != SPI_OK_FINISH)
383  elog(ERROR, "SPI_finish failed: %s", SPI_result_code_string(rc));
384 
385  return retval;
386 }
387 
388 /* ----------
389  * plpgsql_validator
390  *
391  * This function attempts to validate a PL/pgSQL function at
392  * CREATE FUNCTION time.
393  * ----------
394  */
396 
397 Datum
399 {
400  Oid funcoid = PG_GETARG_OID(0);
401  HeapTuple tuple;
402  Form_pg_proc proc;
403  char functyptype;
404  int numargs;
405  Oid *argtypes;
406  char **argnames;
407  char *argmodes;
408  bool is_dml_trigger = false;
409  bool is_event_trigger = false;
410  int i;
411 
412  if (!CheckFunctionValidatorAccess(fcinfo->flinfo->fn_oid, funcoid))
413  PG_RETURN_VOID();
414 
415  /* Get the new function's pg_proc entry */
416  tuple = SearchSysCache1(PROCOID, ObjectIdGetDatum(funcoid));
417  if (!HeapTupleIsValid(tuple))
418  elog(ERROR, "cache lookup failed for function %u", funcoid);
419  proc = (Form_pg_proc) GETSTRUCT(tuple);
420 
421  functyptype = get_typtype(proc->prorettype);
422 
423  /* Disallow pseudotype result */
424  /* except for TRIGGER, RECORD, VOID, or polymorphic */
425  if (functyptype == TYPTYPE_PSEUDO)
426  {
427  /* we assume OPAQUE with no arguments means a trigger */
428  if (proc->prorettype == TRIGGEROID ||
429  (proc->prorettype == OPAQUEOID && proc->pronargs == 0))
430  is_dml_trigger = true;
431  else if (proc->prorettype == EVTTRIGGEROID)
432  is_event_trigger = true;
433  else if (proc->prorettype != RECORDOID &&
434  proc->prorettype != VOIDOID &&
435  !IsPolymorphicType(proc->prorettype))
436  ereport(ERROR,
437  (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
438  errmsg("PL/pgSQL functions cannot return type %s",
439  format_type_be(proc->prorettype))));
440  }
441 
442  /* Disallow pseudotypes in arguments (either IN or OUT) */
443  /* except for RECORD and polymorphic */
444  numargs = get_func_arg_info(tuple,
445  &argtypes, &argnames, &argmodes);
446  for (i = 0; i < numargs; i++)
447  {
448  if (get_typtype(argtypes[i]) == TYPTYPE_PSEUDO)
449  {
450  if (argtypes[i] != RECORDOID &&
451  !IsPolymorphicType(argtypes[i]))
452  ereport(ERROR,
453  (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
454  errmsg("PL/pgSQL functions cannot accept type %s",
455  format_type_be(argtypes[i]))));
456  }
457  }
458 
459  /* Postpone body checks if !check_function_bodies */
461  {
462  LOCAL_FCINFO(fake_fcinfo, 0);
463  FmgrInfo flinfo;
464  int rc;
465  TriggerData trigdata;
466  EventTriggerData etrigdata;
467 
468  /*
469  * Connect to SPI manager (is this needed for compilation?)
470  */
471  if ((rc = SPI_connect()) != SPI_OK_CONNECT)
472  elog(ERROR, "SPI_connect failed: %s", SPI_result_code_string(rc));
473 
474  /*
475  * Set up a fake fcinfo with just enough info to satisfy
476  * plpgsql_compile().
477  */
478  MemSet(fake_fcinfo, 0, SizeForFunctionCallInfo(0));
479  MemSet(&flinfo, 0, sizeof(flinfo));
480  fake_fcinfo->flinfo = &flinfo;
481  flinfo.fn_oid = funcoid;
482  flinfo.fn_mcxt = CurrentMemoryContext;
483  if (is_dml_trigger)
484  {
485  MemSet(&trigdata, 0, sizeof(trigdata));
486  trigdata.type = T_TriggerData;
487  fake_fcinfo->context = (Node *) &trigdata;
488  }
489  else if (is_event_trigger)
490  {
491  MemSet(&etrigdata, 0, sizeof(etrigdata));
492  etrigdata.type = T_EventTriggerData;
493  fake_fcinfo->context = (Node *) &etrigdata;
494  }
495 
496  /* Test-compile the function */
497  plpgsql_compile(fake_fcinfo, true);
498 
499  /*
500  * Disconnect from SPI manager
501  */
502  if ((rc = SPI_finish()) != SPI_OK_FINISH)
503  elog(ERROR, "SPI_finish failed: %s", SPI_result_code_string(rc));
504  }
505 
506  ReleaseSysCache(tuple);
507 
508  PG_RETURN_VOID();
509 }
PLpgSQL_function * plpgsql_compile_inline(char *proc_source)
Definition: pl_comp.c:841
#define SPI_OK_CONNECT
Definition: spi.h:53
void plpgsql_free_function_memory(PLpgSQL_function *func)
Definition: pl_funcs.c:737
Definition: fmgr.h:56
#define CALLED_AS_EVENT_TRIGGER(fcinfo)
Definition: event_trigger.h:39
#define IsA(nodeptr, _type_)
Definition: nodes.h:576
PG_FUNCTION_INFO_V1(plpgsql_call_handler)
#define GETSTRUCT(TUP)
Definition: htup_details.h:655
MemoryContext fn_mcxt
Definition: fmgr.h:65
void plpgsql_exec_event_trigger(PLpgSQL_function *func, EventTriggerData *trigdata)
Definition: pl_exec.c:1128
#define TEXTDOMAIN
Definition: elog.h:144
int SPI_connect_ext(int options)
Definition: spi.c:95
Definition: guc.h:164
char * plpgsql_extra_warnings_string
Definition: pl_handler.c:50
int SPI_connect(void)
Definition: spi.c:89
#define castNode(_type_, nodeptr)
Definition: nodes.h:594
#define GUC_check_errdetail
Definition: guc.h:413
#define PointerGetDatum(X)
Definition: postgres.h:556
#define PG_GETARG_DATUM(n)
Definition: fmgr.h:263
#define PLPGSQL_XCHECK_STRICTMULTIASSIGNMENT
Definition: plpgsql.h:1198
char * pstrdup(const char *in)
Definition: mcxt.c:1186
#define PLPGSQL_XCHECK_NONE
Definition: plpgsql.h:1195
#define SizeForFunctionCallInfo(nargs)
Definition: fmgr.h:102
int SPI_finish(void)
Definition: spi.c:176
int get_func_arg_info(HeapTuple procTup, Oid **p_argtypes, char ***p_argnames, char **p_argmodes)
Definition: funcapi.c:863
void plpgsql_HashTableInit(void)
Definition: pl_comp.c:2531
#define PLPGSQL_XCHECK_SHADOWVAR
Definition: plpgsql.h:1196
#define gettext_noop(x)
Definition: c.h:1148
Definition: nodes.h:525
int plpgsql_extra_errors
Definition: pl_handler.c:53
int errcode(int sqlerrcode)
Definition: elog.c:608
char get_typtype(Oid typid)
Definition: lsyscache.c:2407
#define MemSet(start, val, len)
Definition: c.h:962
char * format_type_be(Oid type_oid)
Definition: format_type.c:326
int pg_strcasecmp(const char *s1, const char *s2)
Definition: pgstrcasecmp.c:36
bool check_function_bodies
Definition: guc.c:503
unsigned int Oid
Definition: postgres_ext.h:31
void ** find_rendezvous_variable(const char *varName)
Definition: dfmgr.c:671
Datum plpgsql_inline_handler(PG_FUNCTION_ARGS)
Definition: pl_handler.c:293
void DefineCustomEnumVariable(const char *name, const char *short_desc, const char *long_desc, int *valueAddr, int bootValue, const struct config_enum_entry *options, GucContext context, int flags, GucEnumCheckHook check_hook, GucEnumAssignHook assign_hook, GucShowHook show_hook)
Definition: guc.c:8737
Datum plpgsql_validator(PG_FUNCTION_ARGS)
Definition: pl_handler.c:398
char * plpgsql_extra_errors_string
Definition: pl_handler.c:51
GucSource
Definition: guc.h:105
#define malloc(a)
Definition: header.h:50
void FreeExecutorState(EState *estate)
Definition: execUtils.c:190
void pfree(void *pointer)
Definition: mcxt.c:1056
PLpgSQL_function * plpgsql_compile(FunctionCallInfo fcinfo, bool forValidator)
Definition: pl_comp.c:135
#define ObjectIdGetDatum(X)
Definition: postgres.h:507
#define ERROR
Definition: elog.h:43
struct PLpgSQL_execstate * cur_estate
Definition: plpgsql.h:1028
bool CheckFunctionValidatorAccess(Oid validatorOid, Oid functionOid)
Definition: fmgr.c:1986
#define SPI_OPT_NONATOMIC
Definition: spi.h:71
unsigned long use_count
Definition: plpgsql.h:1029
Definition: guc.h:75
void EmitWarningsOnPlaceholders(const char *className)
Definition: guc.c:8765
int plpgsql_extra_warnings
Definition: pl_handler.c:52
const char * SPI_result_code_string(int code)
Definition: spi.c:1705
static const struct config_enum_entry variable_conflict_options[]
Definition: pl_handler.c:37
#define PG_GETARG_OID(n)
Definition: fmgr.h:270
bool SplitIdentifierString(char *rawstring, char separator, List **namelist)
Definition: varlena.c:3652
MemoryContext CurrentMemoryContext
Definition: mcxt.c:38
#define PLPGSQL_XCHECK_TOOMANYROWS
Definition: plpgsql.h:1197
void _PG_init(void)
Definition: pl_handler.c:145
#define ereport(elevel, rest)
Definition: elog.h:141
PLpgSQL_plugin ** plpgsql_plugin_ptr
Definition: pl_handler.c:56
EState * CreateExecutorState(void)
Definition: execUtils.c:88
static void plpgsql_extra_warnings_assign_hook(const char *newvalue, void *extra)
Definition: pl_handler.c:127
HeapTuple SearchSysCache1(int cacheId, Datum key1)
Definition: syscache.c:1116
#define PG_FINALLY()
Definition: elog.h:339
PG_MODULE_MAGIC
Definition: pl_handler.c:34
void DefineCustomStringVariable(const char *name, const char *short_desc, const char *long_desc, char **valueAddr, const char *bootValue, GucContext context, int flags, GucStringCheckHook check_hook, GucStringAssignHook assign_hook, GucShowHook show_hook)
Definition: guc.c:8712
uintptr_t Datum
Definition: postgres.h:367
void RegisterSubXactCallback(SubXactCallback callback, void *arg)
Definition: xact.c:3534
void ReleaseSysCache(HeapTuple tuple)
Definition: syscache.c:1164
FormData_pg_proc * Form_pg_proc
Definition: pg_proc.h:133
#define InvalidOid
Definition: postgres_ext.h:36
Oid fn_oid
Definition: fmgr.h:59
bool plpgsql_print_strict_params
Definition: pl_handler.c:46
#define PG_RETURN_VOID()
Definition: fmgr.h:339
#define LOCAL_FCINFO(name, nargs)
Definition: fmgr.h:110
int plpgsql_variable_conflict
Definition: pl_handler.c:44
#define PG_CATCH()
Definition: elog.h:332
#define HeapTupleIsValid(tuple)
Definition: htup.h:78
#define CALLED_AS_TRIGGER(fcinfo)
Definition: trigger.h:25
Datum plpgsql_exec_function(PLpgSQL_function *func, FunctionCallInfo fcinfo, EState *simple_eval_estate, bool atomic)
Definition: pl_exec.c:450
#define Assert(condition)
Definition: c.h:739
#define lfirst(lc)
Definition: pg_list.h:190
SubTransactionId GetCurrentSubTransactionId(void)
Definition: xact.c:707
void RegisterXactCallback(XactCallback callback, void *arg)
Definition: xact.c:3479
static void plpgsql_extra_errors_assign_hook(const char *newvalue, void *extra)
Definition: pl_handler.c:133
#define SPI_OK_FINISH
Definition: spi.h:54
#define PG_RE_THROW()
Definition: elog.h:363
#define DatumGetPointer(X)
Definition: postgres.h:549
int errmsg(const char *fmt,...)
Definition: elog.c:822
NodeTag type
Definition: trigger.h:32
void list_free(List *list)
Definition: list.c:1377
#define elog(elevel,...)
Definition: elog.h:228
int i
void pg_bindtextdomain(const char *domain)
Definition: miscinit.c:1607
void plpgsql_subxact_cb(SubXactEvent event, SubTransactionId mySubid, SubTransactionId parentSubid, void *arg)
Definition: pl_exec.c:8298
static bool plpgsql_extra_checks_check_hook(char **newvalue, void **extra, GucSource source)
Definition: pl_handler.c:60
char * source_text
Definition: parsenodes.h:2861
#define PG_FUNCTION_ARGS
Definition: fmgr.h:188
HeapTuple plpgsql_exec_trigger(PLpgSQL_function *func, TriggerData *trigdata)
Definition: pl_exec.c:885
bool plpgsql_check_asserts
Definition: pl_handler.c:48
#define PG_TRY()
Definition: elog.h:322
void DefineCustomBoolVariable(const char *name, const char *short_desc, const char *long_desc, bool *valueAddr, bool bootValue, GucContext context, int flags, GucBoolCheckHook check_hook, GucBoolAssignHook assign_hook, GucShowHook show_hook)
Definition: guc.c:8626
Definition: pg_list.h:50
Datum plpgsql_call_handler(PG_FUNCTION_ARGS)
Definition: pl_handler.c:222
#define PG_END_TRY()
Definition: elog.h:347
#define GUC_LIST_INPUT
Definition: guc.h:204
#define PLPGSQL_XCHECK_ALL
Definition: plpgsql.h:1199
void plpgsql_xact_cb(XactEvent event, void *arg)
Definition: pl_exec.c:8267