Return Values for SELECT or DELETE UDFs - 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
Language
English (United States)
Last Update
2023-07-11
dita:mapPath
iiv1628111441820.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
B035-1147
lifecycle
latest
Product Category
Teradata Vantageā„¢

SELECT and DELETE UDFs should return the following values in the result and corresponding indicator parameters. The return values are based on the data type and NULL option defined for the constraint object.

  • If the constraint data type is SMALLINT or BYTE(n) and the constraint does not allow nulls, then the valid return values are:
    Return Value Description
    'T' Indicates that the call passed the security policy. The SELECT or DELETE operation is performed.
    'F' Indicates that the call failed to pass the security policy. The SELECT or DELETE is not performed and the system will move to the next row.
  • If the constraint data type is SMALLINT or BYTE(n) and the constraint allows nulls, then the valid return values are:
    IF the Return Indicator Value is... AND the Return Value is... THEN...
    0 'T' the call passed the security policy. The SELECT or DELETE operation is performed.
    0 'F' the call failed to pass the security policy. The SELECT or DELETE operation is not performed and the system will move to the next row.
    The UDF cannot return -1 as the value for the return indicator parameter. This is an invalid result.