Return Value - 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™

FNC_AMPInfo returns a pointer to an AMP_Info_t structure.

The AMP_Info_t structure is defined as:

typedef struct {
    unsigned short NodeId;
    unsigned short AMPId;
    unsigned short LowestAMPOnNode;
} AMP_Info_t;
Member … Specifies …
NodeId the unique number of the node.
AMPId the unique number of the AMP.
LowestAMPOnNode

whether the current AMP is the lowest AMP on the same node as the invoking AMP.

If this function is invoked from a table operator that is associated with a map, then LowestAMPOnNode specifies whether the current AMP is the lowest AMP on the same node within the specified map.

A table function or operator that allows only the lowest AMP vproc to participate can use this field.

The value of LowestAMPOnNode is as follows:
  • Nonzero if the current AMP is the lowest AMP on the node.
  • Zero if the current AMP is not the lowest AMP on the node.