0% found this document useful (0 votes)
11 views1 page

Create Table

The SQL CREATE TABLE statement is utilized to create a new table in a database. The syntax includes specifying the table name and defining its columns along with their data types. An example provided illustrates the creation of a 'Persons' table with five specific columns.

Uploaded by

Bindiya Ramchurn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views1 page

Create Table

The SQL CREATE TABLE statement is utilized to create a new table in a database. The syntax includes specifying the table name and defining its columns along with their data types. An example provided illustrates the creation of a 'Persons' table with five specific columns.

Uploaded by

Bindiya Ramchurn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

The SQL CREATE TABLE Statement

The CREATE TABLE statement is used to create a new table in a database.


Syntax
CREATE TABLE table_name (
column1 datatype,
column2 datatype,
column3 datatype,
....
);
SQL CREATE TABLE Example
The following example creates a table called "Persons" that contains five columns: PersonID,
LastName, FirstName, Address, and City:
Example
CREATE TABLE Persons (
PersonID int,
LastName varchar(255),
FirstName varchar(255),
Address varchar(255),
City varchar(255)
);

You might also like