FNC_TblGetCtrlCtx Function | C Library Functions | Teradata Vantage - FNC_TblGetCtrlCtx - Analytics Database - Teradata Vantage

SQL External Routine Programming

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
ft:locale
en-US
ft:lastEdition
2025-03-30
dita:mapPath
iiv1628111441820.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
qnu1472247494689
lifecycle
latest
Product Category
Teradata Vantageā„¢

Get the address of a previously allocated control scratchpad to retain data between iterations of a local table function copy.

FNC_TblGetCtrlCtx returns the address of the control scratchpad that a local table function copy can use to retain data between iterations.

The return value is a NULL pointer if the general scratchpad has not been previously allocated with a call to FNC_TblAllocCtrlCtx.

Use this library function when the return value of FNC_GetPhase is TBL_MODE_CONST, indicating that the SELECT statement invoked the table function with constant expression input arguments.

For example:

SELECT *
FROM TABLE (table_function_1('STRING_CONSTANT'))
AS table_1;