SQL ALTER

SQL ALTER

ALTER command is used to add, delete, or modify existing objects in a database.

Syntax:

ALTER TABLE table1 ADD col1 datatype

Adds  a new column to table1

ALTER TABLE table1 DROP col1

Drops col1 from table1

195 views

Return to top