FNC_TblOpGetCustomValuesOf Function | C Library Functions | Teradata Vantage - FNC_TblOpGetCustomValuesOf - Advanced SQL Engine - Teradata Database

SQL External Routine Programming

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-24
dita:mapPath
qwr1571437338192.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1147
lifecycle
previous
Product Category
Teradata Vantage™

Purpose

Retrieves all the values associated with a given key in a Custom clause and their corresponding lengths.

Syntax

int
FNC_TblOpGetCustomValuesOf(Key_info_t *key);
Key_info_t *key
the location of the data structure where key is specified and where values and lengths will be placed.

For details about the Key_info_t structure, see Table Operator Data Structures.

Return Value

The values associated with a given key in a Custom clause and the length of each value.

The value that is returned can be an OID (object identifier). The OID is in the form of a client locator.

Usage Notes

Before calling FNC_TblOpGetCustomValuesOf, you must allocate memory for the values to be returned:

key->values_r = FNC_malloc(sizeof(values_t)*key->numOfVal);

You must release the memory when the values are no longer needed:

FNC_free(key->values_r);

Related Topics

For details about the Custom clause of a table operator, see information about the SELECT statement FROM clause in Teradata Vantage™ - SQL Data Manipulation Language, B035-1146.

Example Using FNC_TblOpGetCustomValuesOf

See C Table Operator for an example of how to use this function.