Add column,constraint and modify datatype
Alter table statement
The ALTER TABLE
statement is used to add, delete, or modify columns in an existing table and is
also used to add and drop various constraints on an existing table
->Add
column
Syntax:
ALTER TABLE table_name
ADD column_name datatype;
->Add
constraint
Syntax:
ALTER TABLE
table_name add constraint constraint_name(column_name);
->MODIFY
COLUMN
Syntax:
ALTER TABLE table_name
MODIFY COLUMN column_name datatype;
No comments