Can I add a key and partitions to a table by using the Alter statement, or are these best handled by creating a new table with the keys and partitions defined and then inserting the old table data into the new? The table is very, very large.
In Teradata ALTER Table will use to add COLUMN,PRIMARY KEY,CONSTRAINT and for DROP COLUMN,CONSTRAINT. But if you try to add primary key constraint on existing Table,Teradata will create Unique Secondary Index(USI). If you selectec the column which is already UPI(Unique Primary Index).
If you still need then you have to recreate the table without mention PI. Teradata will create Primary Key Column as Primary Index column.