Analytics Database Analytic Function Syntax | Teradata Vantage - Function Syntax Descriptions - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
Language
English (United States)
Last Update
2024-04-03
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905

SELECT Statement Clauses

The function syntax descriptions in this document are SQL SELECT statements. For simplicity, the descriptions do not show every possible SELECT statement clause. However, you can use any valid SELECT statement clauses. For information about SELECT statement options, see SQL Data Manipulation Language.

Many examples in this document use ORDER BY clauses that the function syntax descriptions do not show.

Function Syntax Element Order

Function syntax elements must appear after the USING clause, but they need not appear in the order shown in the function syntax description.

Many examples in this document do not specify their syntax elements in the order shown in the function syntax description.

Function Input Types

  • PARTITION BY expression:

    The syntax defines the distribution/partitioning of the input result set before the function operates on it. All AMPs process the partitions parallelly, but if there are multiple partitions per AMP, then each partition is processed sequentially.

  • PARTITION BY ANY:

    The syntax does not alter the data distribution of input and lets the function operate on the input result set without any redistribution. If there is no PARTITION BY expression syntax, it defaults to the PARTITION BY ANY syntax. The entire result set per AMP forms a single group or a partition.

  • DIMENSION:

    The syntax duplicates the input result set to all AMPs before the function operates on it. You can use this syntax for multiple inputs only.

  • HASH BY expression:

    The syntax defines the distribution/partitioning of the input result set before the function operates on it. However, unlike PARTITION BY expression, it does not sort the result set after partitioning, and the entire result set per AMP forms a single group or partition. The HASH BY expression is always supported with the PARTITION BY ANY clause.