17.10 - System-Derived and System-Generated Columns - Advanced SQL Engine - Teradata Database

Teradata Vantageā„¢ - SQL Fundamentals

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1141-171K
Language
English (United States)

In addition to the table columns that you define, tables contain columns that Vantage generates or derives dynamically.

Column Description
Identity A column that was specified with the GENERATED ALWAYS AS IDENTITY or GENERATED BY DEFAULT AS IDENTITY option in the table definition.
Object Identifier (OID) For a table that has LOB columns, OID columns store pointers to subtables that store the actual LOB data.
PARTITION For a table that is defined with a partitioned primary index (PPI), the PARTITION column provides the partition number of the combined partitioning expression associated with a row, where the combined partitioning expression is derived from the partitioning expressions defined for each level of the PPI. This is zero for a table that does not have a PPI.
PARTITION#L1 through PARTITION#L62 For tables that are defined with a multilevel PPI, these columns provide the partition number associated with the corresponding level. These are zero for a table that does not have a PPI and zero if the level is greater than the number of partitions.
ROWID Contains the row identifier value that uniquely identifies the row.

Restrictions apply to using the system-derived and system-generated columns in SQL statements. For example, you can use the keywords PARTITION and PARTITION#L1 through PARTITION#L15 in a query where a table column can be referenced, but you can only use the keyword ROWID in a CREATE JOIN INDEX statement.