postgresql_16:7.1.11.2 Parameters
PostgreSQL 16 > Reference > SQL Commands > ALTER FOREIGN TABLE > Parameters
*name*
The name (possibly schema-qualified) of an existing foreign table to alter. If ONLY is specified before the table name, only that table is altered. If ONLY is not specified, the table and all its descendant tables (if any) are altered. Optionally, * can be specified after the table name to explicitly indicate that descendant tables are included.
*column_name*
Name of a new or existing column.
*new_column_name*
New name for an existing column.
*new_name*
New name for the table.
*data_type*
Data type of the new column, or new data type for an existing column.
*table_constraint*
New table constraint for the foreign table.
*constraint_name*
Name of an existing constraint to drop.
CASCADE
Automatically drop objects that depend on the dropped column or constraint (for example, views referencing the column), and in turn all objects that depend on those objects (see (see postgresql_16:3.2.14)).
RESTRICT
Refuse to drop the column or constraint if there are any dependent objects. This is the default behavior.
*trigger_name*
Name of a single trigger to disable or enable.
ALL
Disable or enable all triggers belonging to the foreign table. (This requires superuser privilege if any of the triggers are internally generated triggers. The core system does not add such triggers to foreign tables, but add-on code could do so.)
USER
Disable or enable all triggers belonging to the foreign table except for internally generated triggers.
*parent_table*
A parent table to associate or de-associate with this foreign table.
*new_owner*
The user name of the new owner of the table.
*new_schema*
The name of the schema to which the table will be moved.