Recreate a Table | Teradata Vantage - Recreating a Table - Analytics Database - Teradata Vantage

Database Administration

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
ft:locale
en-US
ft:lastEdition
2024-10-04
dita:mapPath
pgf1628096104492.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
ujp1472240543947
lifecycle
latest
Product Category
Teradata Vantage™
You may need to recreate a data table to:
  • Change a default PI to a defined PI for a nonempty table.
  • Add or remove a PI for a nonempty table.
  • Change the PI to a different PI for a nonempty table.
  • Change a NUPI to a UPI in a populated table when there is no USI (however, usually you would just create the USI on the table, and then alter it).
  • Redefine the partitioning of a populated table. In some cases, you can still use ALTER TABLE; see “ALTER TABLE” in Teradata Vantage™ - SQL Data Definition Language Syntax and Examples, B035-1144.
  • Change a data type attribute that affects existing data. For rules on changing data types, see “ALTER TABLE” in Teradata Vantage™ - SQL Data Definition Language Syntax and Examples, B035-1144.
  • Define or delete COMPRESS storage attributes for an existing column.
  • Add columns that would otherwise exceed the maximum for the number of columns defined during the life of a table.
  • Move the table to another database or user.
  • Change the groupings of columns into column partitions.
It is best practice to access a table via a view, especially for tables used by multiple users.

Use the SHOW TABLE or SHOW IN XML TABLE request to display the current table definition, which you can then modify and submit.