In SQL, the ALTER command is used to make changes to the structure of an existing table.
This includes operations such as adding, deleting, or modifying columns.
To add a new column, the syntax is: ALTER TABLE table_name ADD column_name datatype.
- The INSERT command is used to add new rows (records), not columns.
- The UPDATE command is used to change data in existing rows.
- The MODIFY keyword is not valid in standard SQL for altering table structure; it is used in some dialects only for altering column properties, not for adding new columns.
Thus, to add a column, the correct and standard SQL command is ALTER.