MySQL CREATE TABLE Statement

Table of Contents

MySQL CREATE TABLE Example

The following example creates a table called "Persons" that contains five columns: PersonID, LastName, FirstName, Address, and City:

Example 1

CREATE TABLE Persons ( PersonID int, LastName varchar(255), FirstName varchar(255), Address varchar(255), City varchar(255) );

The MySQL DROP TABLE Statement

The DROP TABLE statement is used to drop an existing table in a database.

The following SQL statement drops the existing table "Persons":

Example 2

DROP TABLE Persons;

Document

Document in project

You can Download PDF file.

Refference