PostgreSQL Source Code
git master
|
#include "executor/execdesc.h"
#include "fmgr.h"
#include "nodes/lockoptions.h"
#include "nodes/parsenodes.h"
#include "utils/memutils.h"
Go to the source code of this file.
Data Structures | |
struct | TupOutputState |
Macros | |
#define | EXEC_FLAG_EXPLAIN_ONLY 0x0001 /* EXPLAIN, no ANALYZE */ |
#define | EXEC_FLAG_EXPLAIN_GENERIC 0x0002 /* EXPLAIN (GENERIC_PLAN) */ |
#define | EXEC_FLAG_REWIND 0x0004 /* need efficient rescan */ |
#define | EXEC_FLAG_BACKWARD 0x0008 /* need backward scan */ |
#define | EXEC_FLAG_MARK 0x0010 /* need mark/restore */ |
#define | EXEC_FLAG_SKIP_TRIGGERS 0x0020 /* skip AfterTrigger setup */ |
#define | EXEC_FLAG_WITH_NO_DATA 0x0040 /* REFRESH ... WITH NO DATA */ |
#define | EvalPlanQualSetSlot(epqstate, slot) ((epqstate)->origslot = (slot)) |
#define | do_text_output_oneline(tstate, str_to_emit) |
#define | ResetExprContext(econtext) MemoryContextReset((econtext)->ecxt_per_tuple_memory) |
#define | GetPerTupleExprContext(estate) |
#define | GetPerTupleMemoryContext(estate) (GetPerTupleExprContext(estate)->ecxt_per_tuple_memory) |
#define | ResetPerTupleExprContext(estate) |
Typedefs | |
typedef void(* | ExecutorStart_hook_type) (QueryDesc *queryDesc, int eflags) |
typedef void(* | ExecutorRun_hook_type) (QueryDesc *queryDesc, ScanDirection direction, uint64 count, bool execute_once) |
typedef void(* | ExecutorFinish_hook_type) (QueryDesc *queryDesc) |
typedef void(* | ExecutorEnd_hook_type) (QueryDesc *queryDesc) |
typedef bool(* | ExecutorCheckPerms_hook_type) (List *rangeTable, List *rtePermInfos, bool ereport_on_violation) |
typedef TupleTableSlot *(* | ExecScanAccessMtd) (ScanState *node) |
typedef bool(* | ExecScanRecheckMtd) (ScanState *node, TupleTableSlot *slot) |
typedef struct TupOutputState | TupOutputState |
#define do_text_output_oneline | ( | tstate, | |
str_to_emit | |||
) |
Definition at line 521 of file executor.h.
#define EvalPlanQualSetSlot | ( | epqstate, | |
slot | |||
) | ((epqstate)->origslot = (slot)) |
Definition at line 243 of file executor.h.
#define EXEC_FLAG_BACKWARD 0x0008 /* need backward scan */ |
Definition at line 68 of file executor.h.
#define EXEC_FLAG_EXPLAIN_GENERIC 0x0002 /* EXPLAIN (GENERIC_PLAN) */ |
Definition at line 66 of file executor.h.
#define EXEC_FLAG_EXPLAIN_ONLY 0x0001 /* EXPLAIN, no ANALYZE */ |
Definition at line 65 of file executor.h.
#define EXEC_FLAG_MARK 0x0010 /* need mark/restore */ |
Definition at line 69 of file executor.h.
#define EXEC_FLAG_REWIND 0x0004 /* need efficient rescan */ |
Definition at line 67 of file executor.h.
Definition at line 70 of file executor.h.
#define EXEC_FLAG_WITH_NO_DATA 0x0040 /* REFRESH ... WITH NO DATA */ |
Definition at line 71 of file executor.h.
#define GetPerTupleExprContext | ( | estate | ) |
Definition at line 549 of file executor.h.
#define GetPerTupleMemoryContext | ( | estate | ) | (GetPerTupleExprContext(estate)->ecxt_per_tuple_memory) |
Definition at line 554 of file executor.h.
#define ResetExprContext | ( | econtext | ) | MemoryContextReset((econtext)->ecxt_per_tuple_memory) |
Definition at line 543 of file executor.h.
#define ResetPerTupleExprContext | ( | estate | ) |
Definition at line 558 of file executor.h.
typedef TupleTableSlot*(* ExecScanAccessMtd) (ScanState *node) |
Definition at line 472 of file executor.h.
typedef bool(* ExecScanRecheckMtd) (ScanState *node, TupleTableSlot *slot) |
Definition at line 473 of file executor.h.
typedef bool(* ExecutorCheckPerms_hook_type) (List *rangeTable, List *rtePermInfos, bool ereport_on_violation) |
Definition at line 94 of file executor.h.
typedef void(* ExecutorEnd_hook_type) (QueryDesc *queryDesc) |
Definition at line 90 of file executor.h.
typedef void(* ExecutorFinish_hook_type) (QueryDesc *queryDesc) |
Definition at line 86 of file executor.h.
typedef void(* ExecutorRun_hook_type) (QueryDesc *queryDesc, ScanDirection direction, uint64 count, bool execute_once) |
Definition at line 79 of file executor.h.
typedef void(* ExecutorStart_hook_type) (QueryDesc *queryDesc, int eflags) |
Definition at line 75 of file executor.h.
typedef struct TupOutputState TupOutputState |
TupOutputState* begin_tup_output_tupdesc | ( | DestReceiver * | dest, |
TupleDesc | tupdesc, | ||
const TupleTableSlotOps * | tts_ops | ||
) |
Definition at line 2256 of file execTuples.c.
References CMD_SELECT, generate_unaccent_rules::dest, TupOutputState::dest, MakeSingleTupleTableSlot(), palloc(), _DestReceiver::rStartup, and TupOutputState::slot.
Referenced by CreateReplicationSlot(), ExecuteCallStmt(), ExplainQuery(), IdentifySystem(), ReadReplicationSlot(), SendTablespaceList(), SendXlogRecPtrResult(), ShowAllGUCConfig(), ShowGUCConfigOption(), and StartReplication().
TupleHashTable BuildTupleHashTable | ( | PlanState * | parent, |
TupleDesc | inputDesc, | ||
int | numCols, | ||
AttrNumber * | keyColIdx, | ||
const Oid * | eqfuncoids, | ||
FmgrInfo * | hashfunctions, | ||
Oid * | collations, | ||
long | nbuckets, | ||
Size | additionalsize, | ||
MemoryContext | tablecxt, | ||
MemoryContext | tempcxt, | ||
bool | use_variable_hash_iv | ||
) |
Definition at line 255 of file execGrouping.c.
References BuildTupleHashTableExt().
TupleHashTable BuildTupleHashTableExt | ( | PlanState * | parent, |
TupleDesc | inputDesc, | ||
int | numCols, | ||
AttrNumber * | keyColIdx, | ||
const Oid * | eqfuncoids, | ||
FmgrInfo * | hashfunctions, | ||
Oid * | collations, | ||
long | nbuckets, | ||
Size | additionalsize, | ||
MemoryContext | metacxt, | ||
MemoryContext | tablecxt, | ||
MemoryContext | tempcxt, | ||
bool | use_variable_hash_iv | ||
) |
Definition at line 154 of file execGrouping.c.
References Assert(), CreateStandaloneExprContext(), CreateTupleDescCopy(), TupleHashTableData::cur_eq_func, TupleHashTableData::entrysize, ExecBuildGroupingEqual(), TupleHashTableData::exprcontext, get_hash_memory_limit(), TupleHashTableData::hash_iv, TupleHashTableData::hashtab, TupleHashTableData::in_hash_funcs, TupleHashTableData::inputslot, TupleHashTableData::keyColIdx, MakeSingleTupleTableSlot(), MemoryContextSwitchTo(), murmurhash32(), TupleHashTableData::numCols, palloc(), ParallelWorkerNumber, TupleHashTableData::tab_collations, TupleHashTableData::tab_eq_func, TupleHashTableData::tab_hash_funcs, TupleHashTableData::tablecxt, TupleHashTableData::tableslot, TupleHashTableData::tempcxt, and TTSOpsMinimalTuple.
Referenced by build_hash_table(), buildSubPlanHash(), and BuildTupleHashTable().
void check_exclusion_constraint | ( | Relation | heap, |
Relation | index, | ||
IndexInfo * | indexInfo, | ||
ItemPointer | tupleid, | ||
Datum * | values, | ||
bool * | isnull, | ||
EState * | estate, | ||
bool | newIndex | ||
) |
Definition at line 910 of file execIndexing.c.
References CEOUC_WAIT, check_exclusion_or_unique_constraint(), and values.
Referenced by IndexCheckExclusion().
Definition at line 620 of file execReplication.c.
References CMD_DELETE, CMD_UPDATE, PublicationDesc::cols_valid_for_delete, PublicationDesc::cols_valid_for_update, ereport, errcode(), errdetail(), errhint(), errmsg(), ERROR, OidIsValid, PublicationDesc::pubactions, PublicationActions::pubdelete, PublicationActions::pubupdate, RelationData::rd_rel, RelationBuildPublicationDesc(), RelationGetRelationName, RelationGetReplicaIndex(), PublicationDesc::rf_valid_for_delete, and PublicationDesc::rf_valid_for_update.
Referenced by CheckValidResultRel(), ExecSimpleRelationDelete(), ExecSimpleRelationInsert(), and ExecSimpleRelationUpdate().
void CheckSubscriptionRelkind | ( | char | relkind, |
const char * | nspname, | ||
const char * | relname | ||
) |
Definition at line 707 of file execReplication.c.
References ereport, errcode(), errdetail_relkind_not_supported(), errmsg(), ERROR, and relname.
Referenced by AlterSubscription_refresh(), apply_handle_tuple_routing(), CreateSubscription(), and logicalrep_rel_open().
void CheckValidResultRel | ( | ResultRelInfo * | resultRelInfo, |
CmdType | operation | ||
) |
Definition at line 1015 of file execMain.c.
References CheckCmdReplicaIdentity(), CMD_DELETE, CMD_INSERT, CMD_UPDATE, elog(), ereport, errcode(), errhint(), errmsg(), ERROR, FdwRoutine::ExecForeignDelete, FdwRoutine::ExecForeignInsert, FdwRoutine::ExecForeignUpdate, FdwRoutine::IsForeignRelUpdatable, MatViewIncrementalMaintenanceIsEnabled(), RelationData::rd_rel, RelationGetRelationName, ResultRelInfo::ri_FdwRoutine, ResultRelInfo::ri_RelationDesc, TriggerDesc::trig_delete_instead_row, TriggerDesc::trig_insert_instead_row, TriggerDesc::trig_update_instead_row, and RelationData::trigdesc.
Referenced by CopyFrom(), ExecFindPartition(), ExecInitModifyTable(), and ExecInitPartitionInfo().
EState* CreateExecutorState | ( | void | ) |
Definition at line 93 of file execUtils.c.
References ALLOCSET_DEFAULT_SIZES, AllocSetContextCreate, CurrentMemoryContext, EState::es_auxmodifytables, EState::es_crosscheck_snapshot, EState::es_direction, EState::es_exprcontexts, EState::es_finished, EState::es_insert_pending_modifytables, EState::es_insert_pending_result_relations, EState::es_instrument, EState::es_jit, EState::es_jit_flags, EState::es_junkFilter, EState::es_opened_result_relations, EState::es_output_cid, EState::es_param_exec_vals, EState::es_param_list_info, EState::es_per_tuple_exprcontext, EState::es_plannedstmt, EState::es_processed, EState::es_query_cxt, EState::es_queryEnv, EState::es_range_table, EState::es_range_table_size, EState::es_relations, EState::es_result_relations, EState::es_rowmarks, EState::es_rteperminfos, EState::es_snapshot, EState::es_sourceText, EState::es_subplanstates, EState::es_top_eflags, EState::es_total_processed, EState::es_trig_target_relations, EState::es_tuple_routing_result_relations, EState::es_tupleTable, EState::es_use_parallel_mode, ForwardScanDirection, InvalidSnapshot, makeNode, MemoryContextSwitchTo(), and NIL.
Referenced by afterTriggerInvokeEvents(), ATRewriteTable(), check_default_partition_contents(), compute_expr_stats(), compute_index_stats(), CopyFrom(), create_edata_for_relation(), create_estate_for_relation(), EvalPlanQualStart(), evaluate_expr(), ExecuteCallStmt(), ExecuteQuery(), ExecuteTruncateGuts(), ExplainExecuteQuery(), fileIterateForeignScan(), get_qual_for_range(), heapam_index_build_range_scan(), heapam_index_validate_scan(), IndexCheckExclusion(), make_build_data(), operator_predicate_proof(), plpgsql_create_econtext(), plpgsql_inline_handler(), standard_ExecutorStart(), StoreAttrDefault(), tuplesort_begin_cluster(), and validateDomainConstraint().
ExprContext* CreateExprContext | ( | EState * | estate | ) |
Definition at line 309 of file execUtils.c.
References ALLOCSET_DEFAULT_SIZES, and CreateExprContextInternal().
Referenced by ExecAssignExprContext(), ExecInitMergeJoin(), ExecInitSubPlan(), ExecuteCallStmt(), MakePerTupleExprContext(), and plpgsql_create_econtext().
ExprContext* CreateStandaloneExprContext | ( | void | ) |
Definition at line 360 of file execUtils.c.
References ALLOCSET_DEFAULT_SIZES, AllocSetContextCreate, ExprContext::caseValue_datum, ExprContext::caseValue_isNull, CurrentMemoryContext, ExprContext::domainValue_datum, ExprContext::domainValue_isNull, ExprContext::ecxt_aggnulls, ExprContext::ecxt_aggvalues, ExprContext::ecxt_callbacks, ExprContext::ecxt_estate, ExprContext::ecxt_innertuple, ExprContext::ecxt_outertuple, ExprContext::ecxt_param_exec_vals, ExprContext::ecxt_param_list_info, ExprContext::ecxt_per_query_memory, ExprContext::ecxt_per_tuple_memory, ExprContext::ecxt_scantuple, and makeNode.
Referenced by BuildTupleHashTableExt(), domain_check_input(), and hypothetical_dense_rank_final().
ExprContext* CreateWorkExprContext | ( | EState * | estate | ) |
Definition at line 324 of file execUtils.c.
References ALLOCSET_DEFAULT_INITSIZE, ALLOCSET_DEFAULT_MAXSIZE, ALLOCSET_DEFAULT_MINSIZE, CreateExprContextInternal(), and work_mem.
Referenced by ExecInitAgg().
void do_text_output_multiline | ( | TupOutputState * | tstate, |
const char * | txt | ||
) |
Definition at line 2304 of file execTuples.c.
References cstring_to_text_with_len(), DatumGetPointer(), do_tup_output(), len, pfree(), PointerGetDatum(), and values.
Referenced by ExplainQuery().
void do_tup_output | ( | TupOutputState * | tstate, |
Datum * | values, | ||
bool * | isnull | ||
) |
Definition at line 2276 of file execTuples.c.
References TupOutputState::dest, ExecClearTuple(), ExecStoreVirtualTuple(), TupleDescData::natts, _DestReceiver::receiveSlot, TupOutputState::slot, TupleTableSlot::tts_isnull, TupleTableSlot::tts_tupleDescriptor, TupleTableSlot::tts_values, and values.
Referenced by CreateReplicationSlot(), do_text_output_multiline(), IdentifySystem(), ReadReplicationSlot(), SendTablespaceList(), SendXlogRecPtrResult(), ShowAllGUCConfig(), and StartReplication().
void end_tup_output | ( | TupOutputState * | tstate | ) |
Definition at line 2334 of file execTuples.c.
References TupOutputState::dest, ExecDropSingleTupleTableSlot(), pfree(), _DestReceiver::rShutdown, and TupOutputState::slot.
Referenced by CreateReplicationSlot(), ExecuteCallStmt(), ExplainQuery(), IdentifySystem(), ReadReplicationSlot(), SendTablespaceList(), SendXlogRecPtrResult(), ShowAllGUCConfig(), ShowGUCConfigOption(), and StartReplication().
TupleTableSlot* EvalPlanQual | ( | EPQState * | epqstate, |
Relation | relation, | ||
Index | rti, | ||
TupleTableSlot * | inputslot | ||
) |
Definition at line 2485 of file execMain.c.
References Assert(), EvalPlanQualBegin(), EvalPlanQualNext(), EvalPlanQualSlot(), ExecClearTuple(), ExecCopySlot(), ExecMaterializeSlot(), EPQState::relsubs_blocked, EPQState::relsubs_done, and TupIsNull.
Referenced by ExecDelete(), ExecMergeMatched(), ExecUpdate(), and GetTupleForTrigger().
void EvalPlanQualBegin | ( | EPQState * | epqstate | ) |
Definition at line 2766 of file execMain.c.
References bms_add_member(), PlanState::chgParam, EPQState::epqParam, EState::es_param_exec_vals, EState::es_plannedstmt, EState::es_range_table_size, EvalPlanQualStart(), ExecSetParamPlanMulti(), Plan::extParam, GetPerTupleExprContext, i, ParamExecData::isnull, list_length(), NIL, PlannedStmt::paramExecTypes, EPQState::parentestate, PlanState::plan, EPQState::plan, EPQState::recheckestate, EPQState::recheckplanstate, EPQState::relsubs_blocked, EPQState::relsubs_done, and ParamExecData::value.
Referenced by EvalPlanQual(), ExecDelete(), and ExecLockRows().
void EvalPlanQualEnd | ( | EPQState * | epqstate | ) |
Definition at line 2997 of file execMain.c.
References EState::es_query_cxt, EState::es_range_table_size, EState::es_subplanstates, EState::es_tupleTable, ExecCloseResultRelations(), ExecEndNode(), ExecResetTupleTable(), FreeExecutorState(), lfirst, MemoryContextSwitchTo(), NIL, EPQState::origslot, EPQState::parentestate, EPQState::recheckestate, EPQState::recheckplanstate, EPQState::relsubs_blocked, EPQState::relsubs_done, EPQState::relsubs_rowmark, EPQState::relsubs_slot, and EPQState::tuple_table.
Referenced by apply_handle_delete_internal(), apply_handle_tuple_routing(), apply_handle_update_internal(), EvalPlanQualSetPlan(), ExecEndLockRows(), ExecEndModifyTable(), and ExecLockRows().
bool EvalPlanQualFetchRowMark | ( | EPQState * | epqstate, |
Index | rti, | ||
TupleTableSlot * | slot | ||
) |
Definition at line 2641 of file execMain.c.
References Assert(), ExecAuxRowMark::ctidAttNo, DatumGetObjectId(), DatumGetPointer(), elog(), ereport, errcode(), errmsg(), ERROR, ExecGetJunkAttribute(), ExecStoreHeapTupleDatum(), GetFdwRoutineForRelation(), ExecRowMark::markType, OidIsValid, EPQState::origslot, ExecRowMark::prti, RelationData::rd_rel, EPQState::recheckestate, FdwRoutine::RefetchForeignRow, ExecRowMark::relation, RelationGetRelationName, ExecRowMark::relid, EPQState::relsubs_rowmark, ROW_MARK_COPY, ROW_MARK_REFERENCE, ExecAuxRowMark::rowmark, RowMarkRequiresRowShareLock, ExecRowMark::rti, SnapshotAny, table_tuple_fetch_row_version(), ExecAuxRowMark::toidAttNo, TupIsNull, and ExecAuxRowMark::wholeAttNo.
Referenced by ExecScanFetch().
void EvalPlanQualInit | ( | EPQState * | epqstate, |
EState * | parentestate, | ||
Plan * | subplan, | ||
List * | auxrowmarks, | ||
int | epqParam, | ||
List * | resultRelations | ||
) |
Definition at line 2554 of file execMain.c.
References EPQState::arowMarks, EPQState::epqParam, EState::es_range_table_size, NIL, EPQState::origslot, palloc0(), EPQState::parentestate, EPQState::plan, EPQState::recheckestate, EPQState::recheckplanstate, EPQState::relsubs_blocked, EPQState::relsubs_done, EPQState::relsubs_rowmark, EPQState::relsubs_slot, EPQState::resultRelations, and EPQState::tuple_table.
Referenced by apply_handle_delete_internal(), apply_handle_tuple_routing(), apply_handle_update_internal(), ExecInitLockRows(), and ExecInitModifyTable().
TupleTableSlot* EvalPlanQualNext | ( | EPQState * | epqstate | ) |
Definition at line 2750 of file execMain.c.
References EState::es_query_cxt, ExecProcNode(), MemoryContextSwitchTo(), EPQState::recheckestate, and EPQState::recheckplanstate.
Referenced by EvalPlanQual(), and ExecLockRows().
Definition at line 2596 of file execMain.c.
References EPQState::arowMarks, EvalPlanQualEnd(), and EPQState::plan.
Referenced by ExecInitModifyTable().
TupleTableSlot* EvalPlanQualSlot | ( | EPQState * | epqstate, |
Relation | relation, | ||
Index | rti | ||
) |
Definition at line 2613 of file execMain.c.
References Assert(), EState::es_query_cxt, MemoryContextSwitchTo(), EPQState::parentestate, EPQState::relsubs_slot, table_slot_create(), and EPQState::tuple_table.
Referenced by EvalPlanQual(), ExecDelete(), ExecLockRows(), ExecMergeMatched(), and ExecUpdate().
|
inlinestatic |
Definition at line 587 of file executor.h.
References EState::es_range_table, and list_nth().
Referenced by conversion_error_callback(), ExecEvalWholeRowVar(), ExecGetRangeTableRelation(), ExecInitBitmapIndexScan(), ExecInitIndexOnlyScan(), ExecInitIndexScan(), GetResultRTEPermissionInfo(), InitPlan(), postgresBeginForeignInsert(), postgresBeginForeignModify(), and postgresBeginForeignScan().
Definition at line 488 of file execUtils.c.
References CreateExprContext(), and PlanState::ps_ExprContext.
Referenced by ExecInitAgg(), ExecInitBitmapHeapScan(), ExecInitBitmapIndexScan(), ExecInitCteScan(), ExecInitCustomScan(), ExecInitForeignScan(), ExecInitFunctionScan(), ExecInitGather(), ExecInitGatherMerge(), ExecInitGroup(), ExecInitHash(), ExecInitHashJoin(), ExecInitIndexOnlyScan(), ExecInitIndexScan(), ExecInitInsertProjection(), ExecInitLimit(), ExecInitMemoize(), ExecInitMerge(), ExecInitMergeJoin(), ExecInitModifyTable(), ExecInitNamedTuplestoreScan(), ExecInitNestLoop(), ExecInitPartitionPruning(), ExecInitProjectSet(), ExecInitResult(), ExecInitSampleScan(), ExecInitSeqScan(), ExecInitSetOp(), ExecInitSubqueryScan(), ExecInitTableFuncScan(), ExecInitTidRangeScan(), ExecInitTidScan(), ExecInitUnique(), ExecInitUpdateProjection(), ExecInitValuesScan(), ExecInitWindowAgg(), and ExecInitWorkTableScan().
Definition at line 543 of file execUtils.c.
References ExecBuildProjectionInfo(), PlanState::plan, PlanState::ps_ExprContext, PlanState::ps_ProjInfo, PlanState::ps_ResultTupleSlot, and Plan::targetlist.
Referenced by ExecConditionalAssignProjectionInfo(), ExecInitAgg(), ExecInitGroup(), ExecInitHashJoin(), ExecInitMergeJoin(), ExecInitNestLoop(), ExecInitResult(), and ExecInitWindowAgg().
void ExecAssignScanProjectionInfo | ( | ScanState * | node | ) |
Definition at line 271 of file execScan.c.
References ExecConditionalAssignProjectionInfo(), PlanState::plan, ScanState::ps, Scan::scanrelid, ScanState::ss_ScanTupleSlot, and TupleTableSlot::tts_tupleDescriptor.
Referenced by ExecInitBitmapHeapScan(), ExecInitCteScan(), ExecInitFunctionScan(), ExecInitIndexScan(), ExecInitNamedTuplestoreScan(), ExecInitSampleScan(), ExecInitSeqScan(), ExecInitSubqueryScan(), ExecInitTableFuncScan(), ExecInitTidRangeScan(), ExecInitTidScan(), ExecInitValuesScan(), and ExecWorkTableScan().
void ExecAssignScanProjectionInfoWithVarno | ( | ScanState * | node, |
int | varno | ||
) |
Definition at line 284 of file execScan.c.
References ExecConditionalAssignProjectionInfo(), ScanState::ps, ScanState::ss_ScanTupleSlot, and TupleTableSlot::tts_tupleDescriptor.
Referenced by ExecInitCustomScan(), ExecInitForeignScan(), and ExecInitIndexOnlyScan().
Definition at line 678 of file execUtils.c.
References ExecSetSlotDescriptor(), and ScanState::ss_ScanTupleSlot.
Referenced by ExecWorkTableScan().
ExprState* ExecBuildAggTrans | ( | AggState * | aggstate, |
struct AggStatePerPhaseData * | phase, | ||
bool | doSort, | ||
bool | doHash, | ||
bool | nullcheck | ||
) |
ExecAuxRowMark* ExecBuildAuxRowMark | ( | ExecRowMark * | erm, |
List * | targetlist | ||
) |
Definition at line 2415 of file execMain.c.
References AttributeNumberIsValid, ExecAuxRowMark::ctidAttNo, elog(), ERROR, ExecFindJunkAttributeInTlist(), ExecRowMark::markType, palloc0(), ExecRowMark::prti, ROW_MARK_COPY, ExecAuxRowMark::rowmark, ExecRowMark::rowmarkId, ExecRowMark::rti, snprintf, ExecAuxRowMark::toidAttNo, and ExecAuxRowMark::wholeAttNo.
Referenced by ExecInitLockRows(), and ExecInitModifyTable().
ExprState* ExecBuildGroupingEqual | ( | TupleDesc | ldesc, |
TupleDesc | rdesc, | ||
const TupleTableSlotOps * | lops, | ||
const TupleTableSlotOps * | rops, | ||
int | numCols, | ||
const AttrNumber * | keyColIdx, | ||
const Oid * | eqfunctions, | ||
const Oid * | collations, | ||
PlanState * | parent | ||
) |
Definition at line 3890 of file execExpr.c.
References ACL_EXECUTE, aclcheck_error(), ACLCHECK_OK, FunctionCallInfoBaseData::args, Assert(), collid, ExprEvalStep::d, EEO_FLAG_IS_QUAL, EEOP_DONE, EEOP_INNER_FETCHSOME, EEOP_INNER_VAR, EEOP_NOT_DISTINCT, EEOP_OUTER_FETCHSOME, EEOP_OUTER_VAR, EEOP_QUAL, ExecComputeSlotInfo(), ExecReadyExpr(), ExprEvalPushStep(), ExprEvalStep::fetch, fmgr_info(), fmgr_info_set_expr, FmgrInfo::fn_addr, ExprEvalStep::func, get_func_name(), GetUserId(), InitFunctionCallInfoData, InvokeFunctionExecuteHook, NullableDatum::isnull, lappend_int(), lfirst_int, makeNode, NIL, object_aclcheck(), OBJECT_FUNCTION, ExprEvalStep::opcode, palloc0(), ExprEvalStep::qualexpr, ExprEvalStep::resnull, ExprEvalStep::resvalue, SizeForFunctionCallInfo, TupleDescAttr, NullableDatum::value, and ExprEvalStep::var.
Referenced by BuildTupleHashTableExt(), ExecInitSubPlan(), and execTuplesMatchPrepare().
ExprState* ExecBuildParamSetEqual | ( | TupleDesc | desc, |
const TupleTableSlotOps * | lops, | ||
const TupleTableSlotOps * | rops, | ||
const Oid * | eqfunctions, | ||
const Oid * | collations, | ||
const List * | param_exprs, | ||
PlanState * | parent | ||
) |
Definition at line 4047 of file execExpr.c.
References ACL_EXECUTE, aclcheck_error(), ACLCHECK_OK, FunctionCallInfoBaseData::args, Assert(), collid, ExprEvalStep::d, EEO_FLAG_IS_QUAL, EEOP_DONE, EEOP_INNER_FETCHSOME, EEOP_INNER_VAR, EEOP_NOT_DISTINCT, EEOP_OUTER_FETCHSOME, EEOP_OUTER_VAR, EEOP_QUAL, ExecComputeSlotInfo(), ExecReadyExpr(), ExprEvalPushStep(), ExprEvalStep::fetch, fmgr_info(), fmgr_info_set_expr, FmgrInfo::fn_addr, ExprEvalStep::func, get_func_name(), GetUserId(), InitFunctionCallInfoData, InvokeFunctionExecuteHook, NullableDatum::isnull, lappend_int(), lfirst_int, list_length(), makeNode, NIL, object_aclcheck(), OBJECT_FUNCTION, ExprEvalStep::opcode, palloc0(), ExprEvalStep::qualexpr, ExprEvalStep::resnull, ExprEvalStep::resvalue, SizeForFunctionCallInfo, TupleDescAttr, NullableDatum::value, and ExprEvalStep::var.
Referenced by ExecInitMemoize().
ProjectionInfo* ExecBuildProjectionInfo | ( | List * | targetList, |
ExprContext * | econtext, | ||
TupleTableSlot * | slot, | ||
PlanState * | parent, | ||
TupleDesc | inputDesc | ||
) |
Definition at line 357 of file execExpr.c.
References ExprEvalStep::assign_tmp, ExprEvalStep::assign_var, attnum, ExprEvalStep::d, EEOP_ASSIGN_INNER_VAR, EEOP_ASSIGN_OUTER_VAR, EEOP_ASSIGN_SCAN_VAR, EEOP_ASSIGN_TMP, EEOP_ASSIGN_TMP_MAKE_RO, EEOP_DONE, ExecCreateExprSetupSteps(), ExecInitExprRec(), ExecReadyExpr(), TargetEntry::expr, ExprEvalPushStep(), exprType(), get_typlen(), if(), INNER_VAR, IsA, lfirst_node, makeNode, ExprEvalStep::opcode, OUTER_VAR, ProjectionInfo::pi_exprContext, ProjectionInfo::pi_state, TargetEntry::resno, TupleDescAttr, and ExprState::type.
Referenced by ExecAssignProjectionInfo(), ExecInitInsertProjection(), ExecInitMerge(), ExecInitModifyTable(), ExecInitPartitionInfo(), and ExecInitSubPlan().
ProjectionInfo* ExecBuildUpdateProjection | ( | List * | targetList, |
bool | evalTargetList, | ||
List * | targetColnos, | ||
TupleDesc | relDesc, | ||
ExprContext * | econtext, | ||
TupleTableSlot * | slot, | ||
PlanState * | parent | ||
) |
Definition at line 517 of file execExpr.c.
References Assert(), ExprEvalStep::assign_tmp, ExprEvalStep::assign_var, attnum, bms_add_member(), bms_is_member(), ExprEvalStep::constval, ExprEvalStep::d, EEOP_ASSIGN_OUTER_VAR, EEOP_ASSIGN_SCAN_VAR, EEOP_ASSIGN_TMP, EEOP_CONST, EEOP_DONE, elog(), ereport, errcode(), errdetail(), errmsg(), ERROR, ExecInitExprRec(), ExecPushExprSetupSteps(), ExecReadyExpr(), TargetEntry::expr, expr_setup_walker(), ExprEvalPushStep(), exprType(), forboth, format_type_be(), ExprSetupInfo::last_outer, ExprSetupInfo::last_scan, lfirst_int, lfirst_node, list_length(), makeNode, TupleDescData::natts, NIL, ExprEvalStep::opcode, ProjectionInfo::pi_exprContext, ProjectionInfo::pi_state, ExprEvalStep::resnull, ExprEvalStep::resvalue, TupleDescAttr, and ExprState::type.
Referenced by ExecInitMerge(), ExecInitModifyTable(), ExecInitPartitionInfo(), and ExecInitUpdateProjection().
bool ExecCheck | ( | ExprState * | state, |
ExprContext * | econtext | ||
) |
Definition at line 842 of file execExpr.c.
References Assert(), DatumGetBool(), EEO_FLAG_IS_QUAL, and ExecEvalExprSwitchContext().
Referenced by ATRewriteTable(), check_default_partition_contents(), domain_check_input(), ExecPartitionCheck(), and ExecRelCheck().
bool ExecCheckIndexConstraints | ( | ResultRelInfo * | resultRelInfo, |
TupleTableSlot * | slot, | ||
EState * | estate, | ||
ItemPointer | conflictTid, | ||
List * | arbiterIndexes | ||
) |
Definition at line 522 of file execIndexing.c.
References CEOUC_WAIT, check_exclusion_or_unique_constraint(), ExprContext::ecxt_scantuple, elog(), ereport, errcode(), errmsg(), ERROR, errtableconstraint(), ExecPrepareQual(), ExecQual(), FormIndexDatum(), GetPerTupleExprContext, i, IndexInfo::ii_ExclusionOps, IndexInfo::ii_Predicate, IndexInfo::ii_PredicateState, IndexInfo::ii_ReadyForInserts, IndexInfo::ii_Unique, INDEX_MAX_KEYS, ItemPointerSetInvalid(), list_member_oid(), NIL, RelationData::rd_index, RelationGetRelationName, ResultRelInfo::ri_IndexRelationDescs, ResultRelInfo::ri_IndexRelationInfo, ResultRelInfo::ri_NumIndices, ResultRelInfo::ri_RelationDesc, and values.
Referenced by ExecInsert().
Definition at line 581 of file execMain.c.
References aclcheck_error(), ACLCHECK_NO_PRIV, Assert(), bms_add_member(), bms_is_member(), bms_num_members(), ExecCheckOneRelPerms(), ExecutorCheckPerms_hook, get_rel_name(), get_rel_relkind(), get_relkind_objtype(), getRTEPermissionInfo(), lfirst_node, list_length(), OidIsValid, RangeTblEntry::perminfoindex, and RTEPermissionInfo::relid.
Referenced by DoCopy(), InitPlan(), and RI_Initial_Check().
int ExecCleanTargetListLength | ( | List * | targetlist | ) |
Definition at line 1150 of file execUtils.c.
References len, and lfirst_node.
Referenced by ApplyRetrieveRule(), check_sql_fn_retval(), and ExecTypeFromTLInternal().
Definition at line 1951 of file execTuples.c.
References ExecTypeFromTLInternal().
Referenced by ExecInitJunkFilter(), PlanCacheComputeResultDesc(), and PortalStart().
void ExecCloseIndices | ( | ResultRelInfo * | resultRelInfo | ) |
Definition at line 231 of file execIndexing.c.
References i, index_close(), ResultRelInfo::ri_IndexRelationDescs, ResultRelInfo::ri_NumIndices, and RowExclusiveLock.
Referenced by apply_handle_delete_internal(), apply_handle_insert_internal(), apply_handle_tuple_routing(), apply_handle_update_internal(), CatalogCloseIndexes(), ExecCleanupTupleRouting(), and ExecCloseResultRelations().
void ExecCloseRangeTableRelations | ( | EState * | estate | ) |
Definition at line 1592 of file execMain.c.
References EState::es_range_table_size, EState::es_relations, i, NoLock, and table_close().
Referenced by CopyFrom(), and ExecEndPlan().
void ExecCloseResultRelations | ( | EState * | estate | ) |
Definition at line 1532 of file execMain.c.
References Assert(), EState::es_opened_result_relations, EState::es_trig_target_relations, ExecCloseIndices(), lfirst, NoLock, ResultRelInfo::ri_ancestorResultRels, ResultRelInfo::ri_NumIndices, ResultRelInfo::ri_RangeTableIndex, ResultRelInfo::ri_RelationDesc, and table_close().
Referenced by afterTriggerInvokeEvents(), CopyFrom(), EvalPlanQualEnd(), and ExecEndPlan().
Definition at line 563 of file execUtils.c.
References ExecAssignProjectionInfo(), ExecInitResultSlot(), PlanState::plan, PlanState::ps_ProjInfo, PlanState::ps_ResultTupleSlot, PlanState::resultops, PlanState::resultopsfixed, PlanState::resultopsset, PlanState::scanops, PlanState::scanopsfixed, PlanState::scanopsset, Plan::targetlist, tlist_matches_tupdesc(), and TTSOpsVirtual.
Referenced by ExecAssignScanProjectionInfo(), ExecAssignScanProjectionInfoWithVarno(), ExecInitGather(), and ExecInitGatherMerge().
void ExecConstraints | ( | ResultRelInfo * | resultRelInfo, |
TupleTableSlot * | slot, | ||
EState * | estate | ||
) |
Definition at line 1931 of file execMain.c.
References Assert(), bms_union(), build_attrmap_by_name_if_req(), TupleDescData::constr, ereport, errcode(), errdetail(), errmsg(), ERROR, errtablecol(), errtableconstraint(), ExecBuildSlotValueDescription(), ExecGetInsertedCols(), ExecGetUpdatedCols(), ExecRelCheck(), execute_attr_map_slot(), TupleConstr::has_not_null, MakeTupleTableSlot(), NameStr, TupleDescData::natts, RelationData::rd_rel, RelationGetDescr, RelationGetRelationName, RelationGetRelid, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_RootResultRelInfo, slot_attisnull(), TTSOpsVirtual, and TupleDescAttr.
Referenced by CopyFrom(), ExecInsert(), ExecSimpleRelationInsert(), ExecSimpleRelationUpdate(), and ExecUpdateAct().
void ExecCreateScanSlotFromOuterPlan | ( | EState * | estate, |
ScanState * | scanstate, | ||
const TupleTableSlotOps * | tts_ops | ||
) |
Definition at line 690 of file execUtils.c.
References ExecGetResultType(), ExecInitScanTupleSlot(), outerPlan, and outerPlanState.
Referenced by ExecInitAgg(), ExecInitGroup(), ExecInitIncrementalSort(), ExecInitMaterial(), ExecInitMemoize(), ExecInitSort(), and ExecInitWindowAgg().
bool execCurrentOf | ( | CurrentOfExpr * | cexpr, |
ExprContext * | econtext, | ||
Oid | table_oid, | ||
ItemPointer | current_tid | ||
) |
Definition at line 44 of file execCurrent.c.
References Assert(), PortalData::atEnd, PortalData::atStart, ExecRowMark::curCtid, CurrentOfExpr::cursor_name, CurrentOfExpr::cursor_param, DatumGetObjectId(), DatumGetPointer(), elog(), ereport, errcode(), errmsg(), ERROR, EState::es_range_table_size, EState::es_rowmarks, QueryDesc::estate, fetch_cursor_param_value(), get_rel_name(), GetPortalByName(), i, IsA, ItemPointerIsValid(), ExecRowMark::markType, QueryDesc::planstate, PORTAL_ONE_SELECT, PortalIsValid, PortalData::queryDesc, ExecRowMark::relid, RowMarkRequiresRowShareLock, search_plan_tree(), SelfItemPointerAttributeNumber, slot_getsysattr(), ScanState::ss_ScanTupleSlot, PortalData::strategy, TableOidAttributeNumber, TupIsNull, and IndexScanDescData::xs_heaptid.
Referenced by TidListEval().
void ExecEndNode | ( | PlanState * | node | ) |
Definition at line 557 of file execProcnode.c.
References bms_free(), check_stack_depth(), PlanState::chgParam, elog(), ERROR, ExecEndAgg(), ExecEndAppend(), ExecEndBitmapAnd(), ExecEndBitmapHeapScan(), ExecEndBitmapIndexScan(), ExecEndBitmapOr(), ExecEndCteScan(), ExecEndCustomScan(), ExecEndForeignScan(), ExecEndFunctionScan(), ExecEndGather(), ExecEndGatherMerge(), ExecEndGroup(), ExecEndHash(), ExecEndHashJoin(), ExecEndIncrementalSort(), ExecEndIndexOnlyScan(), ExecEndIndexScan(), ExecEndLimit(), ExecEndLockRows(), ExecEndMaterial(), ExecEndMemoize(), ExecEndMergeAppend(), ExecEndMergeJoin(), ExecEndModifyTable(), ExecEndNamedTuplestoreScan(), ExecEndNestLoop(), ExecEndProjectSet(), ExecEndRecursiveUnion(), ExecEndResult(), ExecEndSampleScan(), ExecEndSeqScan(), ExecEndSetOp(), ExecEndSort(), ExecEndSubqueryScan(), ExecEndTableFuncScan(), ExecEndTidRangeScan(), ExecEndTidScan(), ExecEndUnique(), ExecEndValuesScan(), ExecEndWindowAgg(), ExecEndWorkTableScan(), and nodeTag.
Referenced by EvalPlanQualEnd(), ExecEndAgg(), ExecEndAppend(), ExecEndBitmapAnd(), ExecEndBitmapHeapScan(), ExecEndBitmapOr(), ExecEndForeignScan(), ExecEndGather(), ExecEndGatherMerge(), ExecEndGroup(), ExecEndHash(), ExecEndHashJoin(), ExecEndIncrementalSort(), ExecEndLimit(), ExecEndLockRows(), ExecEndMaterial(), ExecEndMemoize(), ExecEndMergeAppend(), ExecEndMergeJoin(), ExecEndModifyTable(), ExecEndNestLoop(), ExecEndPlan(), ExecEndProjectSet(), ExecEndRecursiveUnion(), ExecEndResult(), ExecEndSetOp(), ExecEndSort(), ExecEndSubqueryScan(), ExecEndUnique(), and ExecEndWindowAgg().
|
inlinestatic |
Definition at line 332 of file executor.h.
Referenced by advance_windowaggregate(), advance_windowaggregate_base(), array_map(), ATRewriteTable(), do_cast_value(), EvalOrderByExpressions(), exec_eval_simple_expr(), ExecComputeStoredGenerated(), ExecEvalFuncArgs(), ExecHashGetHashValue(), ExecIndexEvalArrayKeys(), ExecIndexEvalRuntimeKeys(), ExecMakeTableFunctionResult(), ExecProjectSRF(), finalize_aggregate(), make_build_data(), MJEvalInnerValues(), MJEvalOuterValues(), NextCopyFrom(), prepare_probe_slot(), process_query_params(), slot_fill_defaults(), StoreAttrDefault(), tfuncFetchRows(), tfuncInitialize(), tfuncLoadRows(), ValuesNext(), WinGetFuncArgCurrent(), WinGetFuncArgInFrame(), and WinGetFuncArgInPartition().
|
inlinestatic |
Definition at line 347 of file executor.h.
References ExprContext::ecxt_per_tuple_memory, and MemoryContextSwitchTo().
Referenced by advance_aggregates(), compute_expr_stats(), evaluate_expr(), EvaluateParams(), ExecCheck(), ExecProject(), ExecQual(), ExecScanSubPlan(), ExecuteCallStmt(), ExecWindowAgg(), FormIndexDatum(), FormPartitionKeyDatum(), get_qual_for_range(), operator_predicate_proof(), partkey_datum_from_expr(), pgoutput_row_filter_exec_expr(), recompute_limits(), tablesample_init(), TidListEval(), TidRangeEval(), and validateDomainConstraint().
TupleTableSlot* ExecFilterJunk | ( | JunkFilter * | junkfilter, |
TupleTableSlot * | slot | ||
) |
Definition at line 247 of file execJunk.c.
References ExecClearTuple(), ExecStoreVirtualTuple(), i, j, JunkFilter::jf_cleanMap, JunkFilter::jf_cleanTupType, JunkFilter::jf_resultSlot, TupleDescData::natts, slot_getallattrs(), TupleTableSlot::tts_isnull, TupleTableSlot::tts_values, and values.
Referenced by ExecEvalWholeRowVar(), ExecutePlan(), and sqlfunction_receive().
AttrNumber ExecFindJunkAttribute | ( | JunkFilter * | junkfilter, |
const char * | attrName | ||
) |
Definition at line 210 of file execJunk.c.
References ExecFindJunkAttributeInTlist(), and JunkFilter::jf_targetList.
AttrNumber ExecFindJunkAttributeInTlist | ( | List * | targetlist, |
const char * | attrName | ||
) |
Definition at line 222 of file execJunk.c.
References InvalidAttrNumber, lfirst, and TargetEntry::resno.
Referenced by create_foreign_modify(), ExecBuildAuxRowMark(), ExecFindJunkAttribute(), and ExecInitModifyTable().
ExecRowMark* ExecFindRowMark | ( | EState * | estate, |
Index | rti, | ||
bool | missing_ok | ||
) |
Definition at line 2392 of file execMain.c.
References elog(), ERROR, and EState::es_rowmarks.
Referenced by ExecInitLockRows(), and ExecInitModifyTable().
void ExecFreeExprContext | ( | PlanState * | planstate | ) |
Definition at line 658 of file execUtils.c.
References PlanState::ps_ExprContext.
Referenced by ExecEndAgg(), ExecEndBitmapHeapScan(), ExecEndCteScan(), ExecEndCustomScan(), ExecEndForeignScan(), ExecEndFunctionScan(), ExecEndGather(), ExecEndGatherMerge(), ExecEndGroup(), ExecEndHash(), ExecEndHashJoin(), ExecEndIndexOnlyScan(), ExecEndIndexScan(), ExecEndLimit(), ExecEndMemoize(), ExecEndMergeJoin(), ExecEndModifyTable(), ExecEndNamedTuplestoreScan(), ExecEndNestLoop(), ExecEndProjectSet(), ExecEndResult(), ExecEndSampleScan(), ExecEndSeqScan(), ExecEndSetOp(), ExecEndSubqueryScan(), ExecEndTableFuncScan(), ExecEndTidRangeScan(), ExecEndTidScan(), ExecEndUnique(), ExecEndValuesScan(), ExecEndWindowAgg(), and ExecEndWorkTableScan().
Bitmapset* ExecGetAllUpdatedCols | ( | ResultRelInfo * | relinfo, |
EState * | estate | ||
) |
Definition at line 1350 of file execUtils.c.
References bms_union(), ExecGetExtraUpdatedCols(), and ExecGetUpdatedCols().
Referenced by ExecARUpdateTriggers(), ExecASUpdateTriggers(), ExecBRUpdateTriggers(), ExecBSUpdateTriggers(), and ExecUpdateLockMode().
List* ExecGetAncestorResultRels | ( | EState * | estate, |
ResultRelInfo * | resultRelInfo | ||
) |
Definition at line 1387 of file execMain.c.
References Assert(), elog(), ERROR, EState::es_instrument, get_partition_ancestors(), InitResultRelInfo(), lappend(), lfirst_oid, makeNode, NIL, NoLock, RelationData::rd_rel, RelationGetRelid, ResultRelInfo::ri_ancestorResultRels, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_RootResultRelInfo, and table_open().
Referenced by ExecCrossPartitionUpdateForeignKey().
TupleConversionMap* ExecGetChildToRootMap | ( | ResultRelInfo * | resultRelInfo | ) |
Definition at line 1237 of file execUtils.c.
References convert_tuples_by_name(), RelationGetDescr, ResultRelInfo::ri_ChildToRootMap, ResultRelInfo::ri_ChildToRootMapValid, ResultRelInfo::ri_RelationDesc, and ResultRelInfo::ri_RootResultRelInfo.
Referenced by adjust_partition_colnos(), AfterTriggerExecute(), AfterTriggerSaveEvent(), ExecCrossPartitionUpdate(), and TransitionTableAddTuple().
Bitmapset* ExecGetExtraUpdatedCols | ( | ResultRelInfo * | relinfo, |
EState * | estate | ||
) |
Definition at line 1340 of file execUtils.c.
References CMD_UPDATE, ExecInitStoredGenerated(), ResultRelInfo::ri_extraUpdatedCols, and ResultRelInfo::ri_GeneratedExprsU.
Referenced by ExecGetAllUpdatedCols(), and index_unchanged_by_update().
Bitmapset* ExecGetInsertedCols | ( | ResultRelInfo * | relinfo, |
EState * | estate | ||
) |
Definition at line 1298 of file execUtils.c.
References TupleConversionMap::attrMap, ExecGetRootToChildMap(), execute_attr_map_cols(), GetResultRTEPermissionInfo(), RTEPermissionInfo::insertedCols, and ResultRelInfo::ri_RootResultRelInfo.
Referenced by ExecConstraints(), ExecPartitionCheckEmitError(), and ExecWithCheckOptions().
|
inlinestatic |
Definition at line 190 of file executor.h.
References Assert(), and slot_getattr().
Referenced by EvalPlanQualFetchRowMark(), ExecLockRows(), ExecMergeMatched(), ExecModifyTable(), and execute_foreign_modify().
Definition at line 793 of file execUtils.c.
References AccessShareLock, Assert(), CheckRelationLockedByMe(), EState::es_relations, exec_rt_fetch(), IsParallelWorker, NoLock, RangeTblEntry::relid, RangeTblEntry::rellockmode, RTE_RELATION, RangeTblEntry::rtekind, and table_open().
Referenced by CreatePartitionPruneState(), ExecInitResultRelation(), ExecOpenScanRelation(), and InitPlan().
Oid ExecGetResultRelCheckAsUser | ( | ResultRelInfo * | relInfo, |
EState * | estate | ||
) |
Definition at line 1412 of file execUtils.c.
References RTEPermissionInfo::checkAsUser, elog(), ERROR, GetResultRTEPermissionInfo(), GetUserId(), RelationGetRelid, and ResultRelInfo::ri_RelationDesc.
Referenced by create_foreign_modify().
const TupleTableSlotOps* ExecGetResultSlotOps | ( | PlanState * | planstate, |
bool * | isfixed | ||
) |
Definition at line 507 of file execUtils.c.
References PlanState::ps_ResultTupleSlot, PlanState::resultops, PlanState::resultopsfixed, PlanState::resultopsset, TTS_FIXED, TupleTableSlot::tts_ops, and TTSOpsVirtual.
Referenced by ExecComputeSlotInfo(), ExecInitAgg(), ExecInitGroup(), ExecInitHashJoin(), ExecInitLimit(), ExecInitLockRows(), ExecInitMergeJoin(), and ExecInitSubqueryScan().
Definition at line 498 of file execUtils.c.
References PlanState::ps_ResultTupleDesc.
Referenced by build_hash_table(), ExecComputeSlotInfo(), ExecCreateScanSlotFromOuterPlan(), ExecIncrementalSort(), ExecInitCteScan(), ExecInitGather(), ExecInitGatherMerge(), ExecInitGroup(), ExecInitHashJoin(), ExecInitIncrementalSort(), ExecInitLimit(), ExecInitMergeJoin(), ExecInitNestLoop(), ExecInitSetOp(), ExecInitSort(), ExecInitSubqueryScan(), ExecInitUnique(), ExecSort(), ExecWorkTableScan(), initialize_phase(), InitPlan(), and switchToPresortedPrefixMode().
TupleTableSlot* ExecGetReturningSlot | ( | EState * | estate, |
ResultRelInfo * | relInfo | ||
) |
Definition at line 1213 of file execUtils.c.
References EState::es_query_cxt, ExecInitExtraTupleSlot(), MemoryContextSwitchTo(), RelationGetDescr, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_ReturningSlot, and table_slot_callbacks().
Referenced by apply_returning_filter(), ExecDelete(), and ExecInsert().
TupleConversionMap* ExecGetRootToChildMap | ( | ResultRelInfo * | resultRelInfo, |
EState * | estate | ||
) |
Definition at line 1263 of file execUtils.c.
References Assert(), build_attrmap_by_name_if_req(), convert_tuples_by_name_attrmap(), EState::es_query_cxt, MemoryContextSwitchTo(), RelationData::rd_rel, RelationGetDescr, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_RootResultRelInfo, ResultRelInfo::ri_RootToChildMap, and ResultRelInfo::ri_RootToChildMapValid.
Referenced by apply_handle_tuple_routing(), CopyFrom(), ExecFindPartition(), ExecGetInsertedCols(), ExecGetUpdatedCols(), ExecInitPartitionInfo(), ExecInitRoutingInfo(), and ExecPrepareTupleRouting().
TupleTableSlot* ExecGetTriggerNewSlot | ( | EState * | estate, |
ResultRelInfo * | relInfo | ||
) |
Definition at line 1191 of file execUtils.c.
References EState::es_query_cxt, ExecInitExtraTupleSlot(), MemoryContextSwitchTo(), RelationGetDescr, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_TrigNewSlot, and table_slot_callbacks().
Referenced by AfterTriggerExecute(), and AfterTriggerSaveEvent().
TupleTableSlot* ExecGetTriggerOldSlot | ( | EState * | estate, |
ResultRelInfo * | relInfo | ||
) |
Definition at line 1169 of file execUtils.c.
References EState::es_query_cxt, ExecInitExtraTupleSlot(), MemoryContextSwitchTo(), RelationGetDescr, ResultRelInfo::ri_RelationDesc, ResultRelInfo::ri_TrigOldSlot, and table_slot_callbacks().
Referenced by AfterTriggerExecute(), AfterTriggerSaveEvent(), ExecARDeleteTriggers(), ExecARUpdateTriggers(), ExecBRDeleteTriggers(), ExecBRUpdateTriggers(), ExecIRDeleteTriggers(), and ExecIRUpdateTriggers().
ResultRelInfo* ExecGetTriggerResultRel | ( |