Using SELECT with NORMALIZE - Analytics Database - Teradata Vantage

SQL Data Manipulation Language

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
2024-12-13
dita:mapPath
pon1628111750298.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
esx1472246586715
lifecycle
latest
Product Category
Teradata Vantageā„¢

Following are the rules and restrictions for using SELECT with NORMALIZE. For information about temporal tables, see Teradata Vantageā„¢ - Temporal Table Support, B035-1182.

The NORMALIZE operation is performed on the first period column in the select list.

For NORMALIZE, at least one column in the select list must be of period data type.

You can use NORMALIZE:
  • on normalized or non-normalized tables
  • in subqueries
  • in the SELECT ... INTO statement

When the first period value specified in the SELECT list is a USING value, a constant value, or DEFAULT function on the period column, NORMALIZE operates like SELECT with DISTINCT.

When the NORMALIZE clause is specified with EXPAND, the rows are expanded and then the result is normalized.

When a query includes NORMALIZE and ORDER BY, the rows are normalized first and the result is ordered on the normalized result.

NORMALIZE is the last operation performed, except when the query includes ORDER BY or INTO. The other operations in a query are performed before NORMALIZE, except ORDER BY and INTO, and then the rows are normalized. If NORMALIZE is specified in a query with aggregation or OLAP, normalize is performed on the final result after the aggregate or OLAP operation.

When SELECT NORMALIZE includes a view list, views are not updatable.

A SELECT statement on a derived period column cannot include NORMALIZE.

You cannot include LOB columns in the select column list for NORMALIZE.

You cannot use NORMALIZE in a SELECT statement that includes the WITH clause or the TOP n operator.

You can use NORMALIZE in a non-recursive seed statement in a recursive query. However, NORMALIZE is not allowed in a recursive statement of a recursive query.

When NORMALIZE is specified in the CURSOR select statement, the CURSOR is not updatable.