UDF Locations | SQL External Routine Programming | Teradata Vantage - UDF Locations - Teradata Vantage - Analytics Database

SQL External Routine Programming

Deployment
VantageCloud
VantageCore
Edition
VMware
Enterprise
IntelliFlex
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ā„¢

When a function call is qualified by a database name, Vantage looks for the UDF in the specified database only.

If you omit the database name, Vantage searches for the UDF in the following order:
  1. The path specified by the SET SESSION UDFSEARCHPATH statement, if set. See Teradata Vantageā„¢ - SQL Data Definition Language Syntax and Examples, B035-1144.
  2. If the UDF implements cast, ordering, or transform functionality for a UDT, search the SYSUDTLIB database.
    Search Result Action
    Function exists, and arguments in function call are compatible with function parameters and follow order of precedence. Search stops.

    If database has multiple functions with same name, Vantage decides which function is best fit. See Calling an Overloaded Function.

    Function does not exist, or arguments in function call are incompatible with function parameters. Statement returns error.
  3. Search the default database for a function with the same name and number of parameters as the function call.
    Search Result Action
    Function exists, and arguments in function call are compatible with function parameters and follow order of precedence. Search stops.

    If database has multiple functions with same name, Vantage decides which function is best fit. See Calling an Overloaded Function.

    Function does not exist, or arguments in function call are incompatible with function parameters. Search continues.
  4. Search the SYSLIB database for a function with the same name and number of parameters as the function call.
    Search Result Action
    Function exists, and arguments in function call are compatible with function parameters and follow order of precedence. Search stops.

    If database has multiple functions with same name, Vantage decides which function is best fit. See Calling an Overloaded Function.

    Function does not exist, or arguments in function call are incompatible with function parameters. Statement returns error.

For the rules of compatibility precedence, see Compatible Types.