|
PostgreSQL Source Code git master
|
#include "access/xact.h"#include "commands/event_trigger.h"#include "commands/trigger.h"#include "executor/spi.h"#include "utils/expandedrecord.h"#include "utils/funccache.h"#include "utils/typcache.h"

Go to the source code of this file.
Macros | |
| #define | TEXTDOMAIN PG_TEXTDOMAIN("plpgsql") |
| #define | _(x) dgettext(TEXTDOMAIN, x) |
| #define | PLPGSQL_OTHERS (-1) |
| #define | PLPGSQL_XCHECK_NONE 0 |
| #define | PLPGSQL_XCHECK_SHADOWVAR (1 << 1) |
| #define | PLPGSQL_XCHECK_TOOMANYROWS (1 << 2) |
| #define | PLPGSQL_XCHECK_STRICTMULTIASSIGNMENT (1 << 3) |
| #define | PLPGSQL_XCHECK_ALL ((int) ~0) |
| #define | YYLTYPE int |
| #define TEXTDOMAIN PG_TEXTDOMAIN("plpgsql") |
| Enumerator | |
|---|---|
| PLPGSQL_RC_OK | |
| PLPGSQL_RC_EXIT | |
| PLPGSQL_RC_RETURN | |
| PLPGSQL_RC_CONTINUE | |
| Enumerator | |
|---|---|
| IDENTIFIER_LOOKUP_NORMAL | |
| IDENTIFIER_LOOKUP_DECLARE | |
| IDENTIFIER_LOOKUP_EXPR | |
Definition at line 1178 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_DTYPE_VAR | |
| PLPGSQL_DTYPE_ROW | |
| PLPGSQL_DTYPE_REC | |
| PLPGSQL_DTYPE_RECFIELD | |
| PLPGSQL_DTYPE_PROMISE | |
Definition at line 62 of file plpgsql.h.
Definition at line 148 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_LABEL_BLOCK | |
| PLPGSQL_LABEL_LOOP | |
| PLPGSQL_LABEL_OTHER | |
Definition at line 52 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_NSTYPE_LABEL | |
| PLPGSQL_NSTYPE_VAR | |
| PLPGSQL_NSTYPE_REC | |
Definition at line 42 of file plpgsql.h.
Definition at line 74 of file plpgsql.h.
Definition at line 168 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_RESOLVE_ERROR | |
| PLPGSQL_RESOLVE_VARIABLE | |
| PLPGSQL_RESOLVE_COLUMN | |
Definition at line 184 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_RWOPT_UNKNOWN | |
| PLPGSQL_RWOPT_NOPE | |
| PLPGSQL_RWOPT_TRANSFER | |
| PLPGSQL_RWOPT_INPLACE | |
Definition at line 194 of file plpgsql.h.
Definition at line 103 of file plpgsql.h.
| Enumerator | |
|---|---|
| PLPGSQL_DML_TRIGGER | |
| PLPGSQL_EVENT_TRIGGER | |
| PLPGSQL_NOT_TRIGGER | |
| Enumerator | |
|---|---|
| PLPGSQL_TTYPE_SCALAR | |
| PLPGSQL_TTYPE_REC | |
| PLPGSQL_TTYPE_PSEUDO | |
Definition at line 93 of file plpgsql.h.
Definition at line 2299 of file pl_comp.c.
References datums_last, PLpgSQL_datum::dno, fb(), i, palloc_array, plpgsql_Datums, PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_VAR, and plpgsql_nDatums.
|
extern |
Definition at line 2238 of file pl_comp.c.
References datums_alloc, fb(), plpgsql_Datums, plpgsql_nDatums, and repalloc().
Referenced by plpgsql_build_recfield(), plpgsql_build_record(), plpgsql_build_variable(), and plpgsql_compile_callback().
|
extern |
Definition at line 435 of file pl_scanner.c.
References appendBinaryStringInfo(), Assert, buf, fb(), and yyextra.
|
extern |
Definition at line 1973 of file pl_comp.c.
References build_datatype(), elog, ERROR, fb(), HeapTupleIsValid, ObjectIdGetDatum(), ReleaseSysCache(), and SearchSysCache1().
Referenced by exec_stmt_case(), plpgsql_build_datatype_arrayof(), plpgsql_compile_callback(), plpgsql_compile_inline(), plpgsql_parse_cwordrowtype(), and plpgsql_parse_wordrowtype().
|
extern |
Definition at line 2107 of file pl_comp.c.
References PLpgSQL_type::atttypmod, PLpgSQL_type::collation, ereport, errcode(), errmsg(), ERROR, fb(), format_type_be(), get_array_type(), OidIsValid, plpgsql_build_datatype(), PLpgSQL_type::typisarray, and PLpgSQL_type::typoid.
|
extern |
Definition at line 1924 of file pl_comp.c.
References Assert, PLpgSQL_rec::dno, fb(), PLpgSQL_rec::firstfield, i, INVALID_TUPLEDESC_IDENTIFIER, palloc0_object, plpgsql_adddatum(), plpgsql_Datums, PLPGSQL_DTYPE_RECFIELD, and pstrdup().
Referenced by plpgsql_parse_dblword(), and plpgsql_parse_tripword().
|
extern |
Definition at line 1830 of file pl_comp.c.
References PLpgSQL_rec::datatype, PLpgSQL_rec::dno, PLpgSQL_rec::dtype, PLpgSQL_rec::erh, fb(), PLpgSQL_rec::firstfield, PLpgSQL_rec::lineno, palloc0_object, plpgsql_adddatum(), PLPGSQL_DTYPE_REC, plpgsql_ns_additem(), PLPGSQL_NSTYPE_REC, pstrdup(), PLpgSQL_rec::rectypeid, and PLpgSQL_rec::refname.
Referenced by plpgsql_build_variable(), and plpgsql_compile_callback().
|
extern |
Definition at line 1767 of file pl_comp.c.
References PLpgSQL_var::datatype, PLpgSQL_var::dno, PLpgSQL_var::dtype, elog, ereport, errcode(), errmsg(), ERROR, fb(), format_type_be(), PLpgSQL_var::freeval, PLpgSQL_var::isnull, PLpgSQL_var::lineno, palloc0_object, plpgsql_adddatum(), plpgsql_build_record(), PLPGSQL_DTYPE_VAR, plpgsql_ns_additem(), PLPGSQL_NSTYPE_VAR, PLPGSQL_TTYPE_PSEUDO, PLPGSQL_TTYPE_REC, PLPGSQL_TTYPE_SCALAR, pstrdup(), PLpgSQL_var::refname, PLpgSQL_type::ttype, PLpgSQL_type::typoid, and PLpgSQL_var::value.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 106 of file pl_comp.c.
References cached_function_compile(), fb(), FunctionCallInfoBaseData::flinfo, FmgrInfo::fn_extra, function, plpgsql_compile_callback(), and plpgsql_delete_callback().
Referenced by plpgsql_call_handler(), and plpgsql_validator().
|
extern |
Definition at line 743 of file pl_comp.c.
References add_dummy_return(), ALLOCSET_DEFAULT_SIZES, AllocSetContextCreate, check_function_bodies, CurrentMemoryContext, PLpgSQL_variable::dno, elog, ERROR, error_context_stack, fb(), function, InvalidOid, MemoryContextSwitchTo(), palloc0_object, plpgsql_build_datatype(), plpgsql_build_variable(), plpgsql_check_syntax, plpgsql_compile_error_callback(), plpgsql_compile_tmp_cxt, plpgsql_curr_compile, plpgsql_DumpExecTree, plpgsql_dumptree(), plpgsql_error_funcname, plpgsql_finish_datums(), PLPGSQL_LABEL_BLOCK, plpgsql_mark_local_assignment_targets(), PLPGSQL_NOT_TRIGGER, plpgsql_ns_init(), plpgsql_ns_push(), plpgsql_print_strict_params, plpgsql_scanner_finish(), plpgsql_scanner_init(), plpgsql_start_datums(), plpgsql_variable_conflict, plpgsql_yyparse(), ErrorContextCallback::previous, compile_error_callback_arg::proc_source, and pstrdup().
Referenced by plpgsql_inline_handler().
|
extern |
Definition at line 772 of file pl_funcs.c.
References plpgsql_free_function_memory().
Referenced by plpgsql_compile().
|
extern |
Definition at line 1601 of file pl_funcs.c.
References PLpgSQL_function::action, PLpgSQL_type::atttypmod, PLpgSQL_var::cursor_explicit_argrow, PLpgSQL_var::cursor_explicit_expr, PLpgSQL_var::datatype, PLpgSQL_function::datums, PLpgSQL_var::default_val, PLpgSQL_datum::dtype, PLpgSQL_rec::dtype, dump_block(), dump_expr(), dump_indent, fb(), PLpgSQL_row::fieldnames, PLpgSQL_function::fn_signature, i, PLpgSQL_var::isconst, j, PLpgSQL_stmt_block::lineno, PLpgSQL_function::ndatums, PLpgSQL_row::nfields, PLpgSQL_var::notnull, PLPGSQL_DTYPE_PROMISE, PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_RECFIELD, PLPGSQL_DTYPE_ROW, PLPGSQL_DTYPE_VAR, PLPGSQL_PROMISE_NONE, printf, PLpgSQL_var::promise, PLpgSQL_var::refname, PLpgSQL_row::refname, PLpgSQL_type::typname, PLpgSQL_type::typoid, and PLpgSQL_row::varnos.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 1175 of file pl_exec.c.
References PLpgSQL_function::action, copy_plpgsql_datums(), ereport, PLpgSQL_execstate::err_text, errcode(), errmsg(), ERROR, error_context_stack, PLpgSQL_execstate::evtrigdata, exec_eval_cleanup(), exec_toplevel_block(), fb(), PLpgSQL_plugin::func_beg, PLpgSQL_plugin::func_end, gettext_noop, plpgsql_destroy_econtext(), plpgsql_estate_setup(), plpgsql_exec_error_callback(), plpgsql_plugin_ptr, PLPGSQL_RC_RETURN, and ErrorContextCallback::previous.
Referenced by plpgsql_call_handler().
|
extern |
Definition at line 493 of file pl_exec.c.
References PLpgSQL_function::action, ReturnSetInfo::allowedModes, FunctionCallInfoBaseData::args, assign_simple_var(), PLpgSQL_execstate::atomic, coerce_function_result_tuple(), copy_plpgsql_datums(), CreateTupleDescCopy(), PLpgSQL_var::datatype, PLpgSQL_execstate::datum_context, DatumGetPointer(), PLpgSQL_function::datums, PLpgSQL_execstate::datums, domain_check(), PLpgSQL_datum::dtype, elog, ereport, PLpgSQL_execstate::err_text, errcode(), errmsg(), ERROR, error_context_stack, exec_cast_value(), exec_eval_cleanup(), exec_move_row(), exec_move_row_from_datum(), exec_set_found(), exec_toplevel_block(), expand_array(), fb(), PLpgSQL_function::fn_argvarnos, PLpgSQL_function::fn_nargs, PLpgSQL_function::fn_retbyval, PLpgSQL_function::fn_retisdomain, PLpgSQL_function::fn_rettype, PLpgSQL_function::fn_rettyplen, PLpgSQL_plugin::func_beg, PLpgSQL_plugin::func_end, get_call_result_type(), gettext_noop, i, IsA, FunctionCallInfoBaseData::isnull, NullableDatum::isnull, PLpgSQL_var::isnull, MemoryContextSwitchTo(), plpgsql_destroy_econtext(), PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_VAR, plpgsql_estate_setup(), plpgsql_exec_error_callback(), plpgsql_plugin_ptr, PLPGSQL_RC_RETURN, ErrorContextCallback::previous, PLpgSQL_execstate::procedure_resowner, FunctionCallInfoBaseData::resultinfo, PLpgSQL_execstate::retisnull, PLpgSQL_execstate::retisset, PLpgSQL_execstate::retistuple, PLpgSQL_execstate::rettype, ReturnSetInfo::returnMode, PLpgSQL_execstate::retval, PLpgSQL_execstate::rsi, ReturnSetInfo::setDesc, ReturnSetInfo::setResult, SFRM_Materialize, SPI_datumTransfer(), TransferExpandedObject(), PLpgSQL_execstate::tuple_store, PLpgSQL_execstate::tuple_store_cxt, PLpgSQL_execstate::tuple_store_desc, TYPEFUNC_COMPOSITE, TYPEFUNC_COMPOSITE_DOMAIN, TYPEFUNC_RECORD, PLpgSQL_type::typisarray, PLpgSQL_type::typlen, NullableDatum::value, PLpgSQL_var::value, VARATT_IS_EXTERNAL_EXPANDED_RO(), and VARATT_IS_EXTERNAL_EXPANDED_RW().
Referenced by plpgsql_call_handler(), and plpgsql_inline_handler().
|
extern |
Definition at line 5452 of file pl_exec.c.
References PLpgSQL_var::datatype, PLpgSQL_execstate::datums, PLpgSQL_datum::dtype, elog, ExpandedRecordHeader::er_tupdesc_id, ExpandedRecordHeader::er_typeid, ereport, PLpgSQL_rec::erh, errcode(), errmsg(), ERROR, expanded_record_lookup_field(), fb(), instantiate_empty_record_variable(), InvalidOid, PLPGSQL_DTYPE_PROMISE, PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_RECFIELD, PLPGSQL_DTYPE_VAR, PLpgSQL_rec::rectypeid, PLpgSQL_rec::refname, PLpgSQL_type::typoid, and unlikely.
Referenced by exec_stmt_foreach_a().
|
extern |
Definition at line 5537 of file pl_exec.c.
References PLpgSQL_type::atttypmod, PLpgSQL_type::collation, PLpgSQL_var::datatype, PLpgSQL_execstate::datums, PLpgSQL_datum::dtype, elog, ExpandedRecordHeader::er_tupdesc_id, ExpandedRecordHeader::er_typeid, ereport, PLpgSQL_rec::erh, errcode(), errmsg(), ERROR, expanded_record_lookup_field(), fb(), instantiate_empty_record_variable(), InvalidOid, PLPGSQL_DTYPE_PROMISE, PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_RECFIELD, PLPGSQL_DTYPE_VAR, PLpgSQL_rec::rectypeid, PLpgSQL_rec::refname, PLpgSQL_type::typoid, and unlikely.
Referenced by make_datum_param().
|
extern |
Definition at line 935 of file pl_exec.c.
References PLpgSQL_function::action, Assert, TupleDescData::constr, convert_tuples_by_position(), copy_plpgsql_datums(), PLpgSQL_execstate::datum_context, DatumGetEOHP(), DatumGetPointer(), PLpgSQL_execstate::datums, deconstruct_composite_datum(), elog, ER_MAGIC, ExpandedRecordHeader::er_magic, ereport, PLpgSQL_execstate::err_text, errcode(), errmsg(), ERROR, error_context_stack, exec_eval_cleanup(), exec_set_found(), exec_toplevel_block(), execute_attr_map_tuple(), expanded_record_get_tupdesc(), expanded_record_get_tuple(), expanded_record_set_field_internal(), expanded_record_set_tuple(), fb(), PLpgSQL_plugin::func_beg, PLpgSQL_plugin::func_end, gettext_noop, TupleConstr::has_generated_stored, i, make_expanded_record_from_exprecord(), make_expanded_record_from_tupdesc(), TupleDescData::natts, PLpgSQL_function::new_varno, PLpgSQL_function::old_varno, plpgsql_destroy_econtext(), plpgsql_estate_setup(), plpgsql_exec_error_callback(), plpgsql_plugin_ptr, PLPGSQL_RC_RETURN, ErrorContextCallback::previous, RelationGetDescr, ReleaseTupleDesc, PLpgSQL_execstate::retisnull, PLpgSQL_execstate::retisset, PLpgSQL_execstate::rettype, PLpgSQL_execstate::retval, SPI_copytuple(), SPI_register_trigger_data(), TriggerData::tg_event, TriggerData::tg_newtuple, TriggerData::tg_relation, TriggerData::tg_trigtuple, PLpgSQL_execstate::trigdata, TRIGGER_FIRED_BEFORE, TRIGGER_FIRED_BY_DELETE, TRIGGER_FIRED_BY_INSERT, TRIGGER_FIRED_BY_UPDATE, TRIGGER_FIRED_FOR_ROW, TupleDescAttr(), type_is_rowtype(), and VARATT_IS_EXTERNAL_EXPANDED().
Referenced by plpgsql_call_handler().
|
extern |
Definition at line 716 of file pl_funcs.c.
References PLpgSQL_function::action, Assert, PLpgSQL_function::cfunc, PLpgSQL_var::cursor_explicit_expr, PLpgSQL_function::datums, PLpgSQL_var::default_val, PLpgSQL_rec::default_val, PLpgSQL_datum::dtype, elog, ERROR, fb(), PLpgSQL_function::fn_cxt, free_expr(), free_stmt(), i, MemoryContextDelete(), PLpgSQL_function::ndatums, PLPGSQL_DTYPE_PROMISE, PLPGSQL_DTYPE_REC, PLPGSQL_DTYPE_RECFIELD, PLPGSQL_DTYPE_ROW, PLPGSQL_DTYPE_VAR, and CachedFunction::use_count.
Referenced by plpgsql_delete_callback(), and plpgsql_inline_handler().
|
extern |
Definition at line 300 of file pl_funcs.c.
References PLPGSQL_GETDIAG_COLUMN_NAME, PLPGSQL_GETDIAG_CONSTRAINT_NAME, PLPGSQL_GETDIAG_CONTEXT, PLPGSQL_GETDIAG_DATATYPE_NAME, PLPGSQL_GETDIAG_ERROR_CONTEXT, PLPGSQL_GETDIAG_ERROR_DETAIL, PLPGSQL_GETDIAG_ERROR_HINT, PLPGSQL_GETDIAG_MESSAGE_TEXT, PLPGSQL_GETDIAG_RETURNED_SQLSTATE, PLPGSQL_GETDIAG_ROUTINE_OID, PLPGSQL_GETDIAG_ROW_COUNT, PLPGSQL_GETDIAG_SCHEMA_NAME, and PLPGSQL_GETDIAG_TABLE_NAME.
Referenced by dump_getdiag().
Definition at line 607 of file pl_scanner.c.
References yyextra.
Referenced by plpgsql_compile_error_callback().
Definition at line 573 of file pl_scanner.c.
References plpgsql_yy_extra_type::cur_line_start, fb(), location_lineno_init(), plpgsql_yy_extra_type::scanorig, and yyextra.
|
extern |
Definition at line 673 of file pl_funcs.c.
References PLpgSQL_function::action, bms_add_member(), bms_free(), fb(), PLpgSQL_function::fn_argvarnos, PLpgSQL_function::fn_nargs, i, and mark_stmt().
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 92 of file pl_funcs.c.
References Assert, fb(), name, ns_top, palloc(), and PLPGSQL_NSTYPE_LABEL.
Referenced by add_parameter_name(), plpgsql_build_record(), plpgsql_build_variable(), and plpgsql_ns_push().
|
extern |
Definition at line 214 of file pl_funcs.c.
References fb(), PLPGSQL_LABEL_LOOP, PLPGSQL_NSTYPE_LABEL, and PLpgSQL_nsitem::prev.
Definition at line 43 of file pl_funcs.c.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 130 of file pl_funcs.c.
References fb(), PLPGSQL_NSTYPE_LABEL, PLPGSQL_NSTYPE_VAR, and PLpgSQL_nsitem::prev.
Referenced by add_parameter_name(), plpgsql_param_ref(), plpgsql_parse_cwordtype(), plpgsql_parse_dblword(), plpgsql_parse_tripword(), plpgsql_parse_word(), plpgsql_parse_wordtype(), and resolve_column_ref().
|
extern |
Definition at line 195 of file pl_funcs.c.
References fb(), name, PLPGSQL_NSTYPE_LABEL, and PLpgSQL_nsitem::prev.
Definition at line 67 of file pl_funcs.c.
References Assert, fb(), PLpgSQL_nsitem::itemtype, ns_top, PLPGSQL_NSTYPE_LABEL, and PLpgSQL_nsitem::prev.
|
extern |
Definition at line 54 of file pl_funcs.c.
References fb(), label, plpgsql_ns_additem(), and PLPGSQL_NSTYPE_LABEL.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 81 of file pl_funcs.c.
References ns_top.
Referenced by add_parameter_name(), plpgsql_parse_cwordtype(), plpgsql_parse_dblword(), plpgsql_parse_tripword(), plpgsql_parse_word(), and plpgsql_parse_wordtype().
|
extern |
Definition at line 1721 of file pl_comp.c.
References ereport, errcode(), errmsg(), ERROR, fb(), get_rel_type_id(), InvalidOid, makeRangeVarFromNameList(), makeTypeNameFromNameList(), MemoryContextSwitchTo(), NoLock, OidIsValid, plpgsql_build_datatype(), plpgsql_compile_tmp_cxt, and RangeVarGetRelid.
|
extern |
Definition at line 1564 of file pl_comp.c.
References Assert, build_datatype(), elog, ereport, errcode(), errmsg(), ERROR, fb(), GETSTRUCT(), HeapTupleIsValid, linitial, list_copy(), list_delete_last(), list_length(), llast, lsecond, makeRangeVar(), makeRangeVarFromNameList(), MemoryContextSwitchTo(), NoLock, ObjectIdGetDatum(), plpgsql_compile_tmp_cxt, plpgsql_Datums, plpgsql_ns_lookup(), plpgsql_ns_top(), PLPGSQL_NSTYPE_REC, PLPGSQL_NSTYPE_VAR, RangeVarGetRelid, ReleaseSysCache(), SearchSysCache1(), SearchSysCacheAttName(), and strVal.
|
extern |
Definition at line 1358 of file pl_comp.c.
References fb(), IDENTIFIER_LOOKUP_DECLARE, PLpgSQL_nsitem::itemno, PLpgSQL_nsitem::itemtype, list_make2, makeString(), plpgsql_build_recfield(), plpgsql_Datums, plpgsql_IdentifierLookup, plpgsql_ns_lookup(), plpgsql_ns_top(), PLPGSQL_NSTYPE_REC, and PLPGSQL_NSTYPE_VAR.
Referenced by plpgsql_yylex().
|
extern |
Definition at line 2174 of file pl_comp.c.
References ereport, errcode(), errmsg(), ERROR, exception_label_map, fb(), i, label, ExceptionLabelMap::label, palloc_object, PLPGSQL_OTHERS, and ExceptionLabelMap::sqlerrstate.
|
extern |
Definition at line 1439 of file pl_comp.c.
References fb(), IDENTIFIER_LOOKUP_DECLARE, PLpgSQL_nsitem::itemno, PLpgSQL_nsitem::itemtype, list_make2, list_make3, makeString(), plpgsql_build_recfield(), plpgsql_Datums, plpgsql_IdentifierLookup, plpgsql_ns_lookup(), plpgsql_ns_top(), and PLPGSQL_NSTYPE_REC.
Referenced by plpgsql_yylex().
|
extern |
Definition at line 1303 of file pl_comp.c.
References elog, ERROR, fb(), IDENTIFIER_LOOKUP_NORMAL, PLpgSQL_nsitem::itemno, PLpgSQL_nsitem::itemtype, NIL, plpgsql_Datums, plpgsql_IdentifierLookup, plpgsql_ns_lookup(), plpgsql_ns_top(), PLPGSQL_NSTYPE_REC, PLPGSQL_NSTYPE_VAR, and word().
Referenced by plpgsql_yylex().
|
extern |
Definition at line 1676 of file pl_comp.c.
References ereport, errcode(), ERRCODE_UNDEFINED_TABLE, errmsg(), ERROR, fb(), get_rel_type_id(), ident, InvalidOid, makeTypeName(), MemoryContextSwitchTo(), OidIsValid, plpgsql_build_datatype(), plpgsql_compile_tmp_cxt, and RelnameGetRelid().
|
extern |
Definition at line 1523 of file pl_comp.c.
References ereport, errcode(), errmsg(), ERROR, fb(), ident, plpgsql_Datums, plpgsql_ns_lookup(), plpgsql_ns_top(), PLPGSQL_NSTYPE_REC, and PLPGSQL_NSTYPE_VAR.
|
extern |
Definition at line 989 of file pl_comp.c.
References ParseState::p_paramref_hook, ParseState::p_post_columnref_hook, ParseState::p_pre_columnref_hook, ParseState::p_ref_hook_state, plpgsql_param_ref(), plpgsql_post_column_ref(), and plpgsql_pre_column_ref().
Referenced by exec_prepare_plan(), and plpgsql_estate_setup().
Definition at line 452 of file pl_scanner.c.
References fb(), internal_yylex(), and push_back_token().
|
extern |
Definition at line 471 of file pl_scanner.c.
References fb(), internal_yylex(), and push_back_token().
|
extern |
Definition at line 401 of file pl_scanner.c.
References fb(), TokenAuxData::lval, push_back_token(), and yyextra.
|
extern |
Definition at line 2138 of file pl_comp.c.
References ereport, errcode(), errmsg(), ERROR, exception_label_map, fb(), i, label, ExceptionLabelMap::label, MAKE_SQLSTATE, and ExceptionLabelMap::sqlerrstate.
Referenced by exec_stmt_raise().
Definition at line 504 of file pl_scanner.c.
References fb(), internalerrposition(), internalerrquery(), pg_mbstrlen_with_len(), plpgsql_yy_extra_type::scanorig, and yyextra.
Referenced by plpgsql_yyerror().
Definition at line 653 of file pl_scanner.c.
References scanner_finish().
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
Definition at line 621 of file pl_scanner.c.
References fb(), IDENTIFIER_LOOKUP_NORMAL, location_lineno_init(), palloc0_object, plpgsql_IdentifierLookup, ReservedPLKeywordTokens, scanner_init(), and str.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 232 of file pl_funcs.c.
References _, PLPGSQL_STMT_ASSERT, PLPGSQL_STMT_ASSIGN, PLPGSQL_STMT_BLOCK, PLPGSQL_STMT_CALL, PLPGSQL_STMT_CASE, PLPGSQL_STMT_CLOSE, PLPGSQL_STMT_COMMIT, PLPGSQL_STMT_DYNEXECUTE, PLPGSQL_STMT_DYNFORS, PLPGSQL_STMT_EXECSQL, PLPGSQL_STMT_EXIT, PLPGSQL_STMT_FETCH, PLPGSQL_STMT_FORC, PLPGSQL_STMT_FOREACH_A, PLPGSQL_STMT_FORI, PLPGSQL_STMT_FORS, PLPGSQL_STMT_GETDIAG, PLPGSQL_STMT_IF, PLPGSQL_STMT_LOOP, PLPGSQL_STMT_OPEN, PLPGSQL_STMT_PERFORM, PLPGSQL_STMT_RAISE, PLPGSQL_STMT_RETURN, PLPGSQL_STMT_RETURN_NEXT, PLPGSQL_STMT_RETURN_QUERY, PLPGSQL_STMT_ROLLBACK, PLPGSQL_STMT_WHILE, and stmt.
Referenced by plpgsql_exec_error_callback().
|
extern |
Definition at line 8765 of file pl_exec.c.
References fb(), FreeExprContext(), next, SimpleEcontextStackEntry::next, pfree(), simple_econtext_stack, SimpleEcontextStackEntry::stack_econtext, SUBXACT_EVENT_ABORT_SUB, SUBXACT_EVENT_COMMIT_SUB, and SimpleEcontextStackEntry::xact_subxid.
Referenced by _PG_init(), and plpgsql_inline_handler().
Definition at line 418 of file pl_scanner.c.
References i, lengthof, and UnreservedPLKeywordTokens.
Definition at line 327 of file pl_scanner.c.
References yyextra.
Definition at line 8723 of file pl_exec.c.
References fb(), FreeExecutorState(), ReleaseAllPlanCacheRefsInOwner(), shared_simple_eval_estate, shared_simple_eval_resowner, simple_econtext_stack, XACT_EVENT_ABORT, XACT_EVENT_COMMIT, XACT_EVENT_PARALLEL_ABORT, XACT_EVENT_PARALLEL_COMMIT, and XACT_EVENT_PREPARE.
Referenced by _PG_init().
|
extern |
Definition at line 534 of file pl_scanner.c.
References _, ereport, errcode(), errmsg(), ERROR, fb(), plpgsql_scanner_errposition(), and yyextra.
Definition at line 160 of file pl_scanner.c.
References AT_STMT_START, fb(), GetScanKeyword(), internal_yylex(), plpgsql_parse_dblword(), plpgsql_parse_tripword(), plpgsql_parse_word(), push_back_token(), ScanKeywordLookup(), UnreservedPLKeywordTokens, and yyextra.
|
extern |
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 51 of file pl_handler.c.
Referenced by _PG_init(), and exec_stmt_assert().
|
extern |
Definition at line 48 of file pl_comp.c.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 53 of file pl_comp.c.
Referenced by plpgsql_compile_callback(), plpgsql_compile_inline(), plpgsql_parse_cwordrowtype(), plpgsql_parse_cwordtype(), plpgsql_parse_wordrowtype(), and plpgsql_start_datums().
|
extern |
Definition at line 50 of file pl_comp.c.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 43 of file pl_comp.c.
Referenced by plpgsql_add_initdatums(), plpgsql_adddatum(), plpgsql_build_recfield(), plpgsql_finish_datums(), plpgsql_parse_cwordtype(), plpgsql_parse_dblword(), plpgsql_parse_tripword(), plpgsql_parse_word(), plpgsql_parse_wordtype(), and plpgsql_start_datums().
|
extern |
Definition at line 47 of file pl_comp.c.
Referenced by plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 46 of file pl_comp.c.
Referenced by plpgsql_compile_callback(), plpgsql_compile_error_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 56 of file pl_handler.c.
Referenced by exec_move_row_from_fields(), exec_stmt_execsql(), plpgsql_compile_callback(), and plpgsql_extra_errors_assign_hook().
|
extern |
Definition at line 55 of file pl_handler.c.
Referenced by exec_move_row_from_fields(), exec_stmt_execsql(), plpgsql_compile_callback(), and plpgsql_extra_warnings_assign_hook().
|
extern |
Definition at line 26 of file pl_scanner.c.
Referenced by plpgsql_parse_dblword(), plpgsql_parse_tripword(), plpgsql_parse_word(), and plpgsql_scanner_init().
|
extern |
Definition at line 42 of file pl_comp.c.
Referenced by plpgsql_add_initdatums(), plpgsql_adddatum(), plpgsql_finish_datums(), and plpgsql_start_datums().
|
extern |
Definition at line 59 of file pl_handler.c.
Referenced by _PG_init(), exec_stmts(), exec_toplevel_block(), plpgsql_estate_setup(), plpgsql_exec_event_trigger(), plpgsql_exec_function(), and plpgsql_exec_trigger().
|
extern |
Definition at line 49 of file pl_handler.c.
Referenced by _PG_init(), plpgsql_compile_callback(), and plpgsql_compile_inline().
|
extern |
Definition at line 47 of file pl_handler.c.
Referenced by _PG_init(), plpgsql_compile_callback(), and plpgsql_compile_inline().