CREATE TABLE Statement
CREATE TABLE statement is used to create a new table in a database. It allows one to specify the name of the table and the name of each column in the table.
INSERT INTO statement is used to add a new record (row) to a table.
It has two forms as shown in the code block:
UPDATE statement is used to edit records (rows) in a table. It usually includes a
SET clause that indicates the column to edit and a
WHERE clause for specifying which record(s) should be updated.
ALTER TABLE Statement
ALTER TABLE statement is used to modify the columns of an existing table. When combined with the
ADD COLUMN clause, it is used to add a new column to a table.
DELETE statement is used to delete records (rows) in a table. This statement does not delete the whole table.
WHERE clause specifies which record or records that should be deleted. If the
WHERE clause is omitted, all records will be deleted.
Column constraints are the rules applied to the values of individual columns:
PRIMARY KEYconstraint can be used to uniquely identify the row.
UNIQUEcolumns have a different value for every row.
NOT NULLcolumns must have a value.
DEFAULTassigns a default value for the column when no value is specified.
There can be only one
PRIMARY KEY column per table and multiple