Fixed Result Row Specification - 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ā„¢

If the CREATE FUNCTION or REPLACE FUNCTION statement specifies a column list for the table function row result, then the table function is said to have a fixed result row specification. The number of output parameters in the Java method parameter list matches the number of columns in the column list in the RETURNS TABLE clause of the CREATE FUNCTION or REPLACE FUNCTION statement.

Here is an example of a CREATE FUNCTION statement for a table function with a fixed result row specification:

CREATE FUNCTION getStoreData (FileToRead INTEGER)
RETURNS TABLE (StoreNo INTEGER, ItemNo INTEGER, QuantSold INTEGER)
LANGUAGE JAVA
NO SQL
EXTERNAL NAME 'JarUDF:UDFExample.getStoreData'
PARAMETER STYLE JAVA;

In this example, the number of result parameters in the table UDF parameter list is three.