ALTER TABLE

ALTER TABLE#

Changes the definition of an existing table by adding a column or constraint, or renaming the table.

Syntax#

ALTER TABLE table ADD column definition / constraint RENAME TO new table name

Arguments#

ADD

Adds a column definition or a table constraint.

RENAME TO

Renames the table.

Examples#

Add a column:

ALTER TABLE dbo.Product ADD Sku nvarchar(40) NULL;

Rename a table:

ALTER TABLE dbo.Product RENAME TO dbo.Item;

See also