MCPcopy Create free account
hub / github.com/apache/cloudberry / func_exec_location

Function func_exec_location

src/backend/utils/cache/lsyscache.c:2512–2529  ·  view source on GitHub ↗

* func_exec_location * Given procedure id, return the function's proexeclocation field */

Source from the content-addressed store, hash-verified

2510 * Given procedure id, return the function's proexeclocation field
2511 */
2512char
2513func_exec_location(Oid funcid)
2514{
2515 HeapTuple tp;
2516 char result;
2517 bool isnull;
2518
2519 tp = SearchSysCache1(PROCOID, ObjectIdGetDatum(funcid));
2520 if (!HeapTupleIsValid(tp))
2521 elog(ERROR, "cache lookup failed for function %u", funcid);
2522
2523 result = DatumGetChar(
2524 SysCacheGetAttr(PROCOID, tp, Anum_pg_proc_proexeclocation, &isnull));
2525 ReleaseSysCache(tp);
2526
2527 Assert(!isnull);
2528 return result;
2529}
2530
2531/* ---------- RELATION CACHE ---------- */
2532

Callers 5

FuncExecLocationMethod · 0.85
ParseFuncOrColumnFunction · 0.85
create_functionscan_pathFunction · 0.85

Calls 5

SearchSysCache1Function · 0.85
ObjectIdGetDatumFunction · 0.85
DatumGetCharFunction · 0.85
SysCacheGetAttrFunction · 0.85
ReleaseSysCacheFunction · 0.85

Tested by

no test coverage detected