SQL Function Types | Teradata Vantage - Types of SQL Functions - Advanced SQL Engine - Teradata Database

SQL Functions, Expressions, and Predicates

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-30
dita:mapPath
tpt1555966086716.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1145
lifecycle
previous
Product Category
Teradata Vantageā„¢
Function Type Definition
Scalar The arguments are individual scalar values of either the same or mixed type that can have different meanings.

The result is a single value or null.

Scalar functions can be used in any SQL statement where an expression can be used.

Aggregate The argument is a group of rows.

The result is a single value or null.

Normally aggregate functions are used in the expression list of a SELECT statement and in the summary list of a WITH clause.

Table The arguments are individual scalar values of either same or mixed type that can have different meanings.

The result is a table.

Table functions can be used only within the FROM clause of a SELECT statement.

Table functions are a form of user-defined functions and are described in Teradata Vantageā„¢ - SQL External Routine Programming , B035-1147 .

Ordered Analytical The arguments are any normal SQL expression.

The result is handled the same way as any other SQL expression. It can be a result column or part of a more complex arithmetic expression.

Ordered analytical functions are used in operations that require an ordered set of results rows or that depend on values in a previous row.