SQL - CREATE Table
SQL - CREATE TableCreating a basic table involves naming the table and defining its columns and each column's data type.
The SQL CREATE TABLE statement is used to create a new table.
CREATE TABLE is the keyword telling the database system what you want to do. In this case, you want to create a new table. The unique name or identifier for the table follows the CREATE TABLE statement.
CREATE TABLE table_name(
PRIMARY KEY( one or more columns )
Then in brackets comes the list defining each column in the table and what sort of data type it is. The syntax becomes clearer with an example below.
A copy of an existing table can be created using a combination of the CREATE TABLE statement and the SELECT statement.