SQL CREATE TABLE

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Extensions
> Step 2: And Like the video. BONUS: You can also share it!

Introduction

The CREATE TABLE statement is used create a new table in the database. A table definition consists of a list of columns, their types, and any integrity constraints.

Syntax

  • CREATE TABLE tableName( [ColumnName1] [datatype1] [, [ColumnName2] [datatype2] ...] )

Parameters

ParameterDetails
tableNameThe name of the table
columnsContains an 'enumeration' of all the columns that the table have. See Create a New Table for more details.

Remarks

Table names must be unique.



Got any SQL Question?