Limitations on Using Automatic Enforcement for Local and Global Temporary Tables
This section includes limitations and related notes on using automatic enforcement of primary and unique key constraints with local and global temporary tables. For general information on temporary tables, see Creating Temporary Tables.
Limitations for Local and Global Temporary Tables
Vertica displays an error message if you add an enabled constraint to a local or global temporary table that contains data. Vertica displays the error because it cannot create projections for enabled constraints on a temporary table if that table is already populated with data.
Limitations Specific to Global Temporary Tables
You cannot use ALTER TABLE to add a new or enable an existing primary or unique key constraint on a global temporary table. Use CREATE TABLE to enable a constraint on a global temporary table.
You can use ALTER TABLE to add a new or enable an existing primary or unique key constraint on a local temporary table if the local temporary table is empty.
Note: You can use ALTER TABLE to disable an already enabled primary or unique key constraint on a global temporary table.