SQLCREATE TABLEDDLtutorial
What is CREATE TABLE in SQL? Creating a table for beginners
CREATE TABLE is the SQL command for "create a new table". Plain words: which columns and what types, what NOT NULL, DEFAULT, PRIMARY KEY, and FOREIGN KEY do, and why thinking about the schema upfront pays off. With before/after tables, common beginner mistakes, and three exercises.
PreviousТипы данных SQL: INT, VARCHAR, NUMERIC, DATE и другиеNextПервичный ключ SQL: PRIMARY KEY и внешний ключ
Related articles
Tasks on this topic
Create the projects TableDrop the departments TableAdd an Employee Email ColumnDrop the salary Column from employeesRename Column 'name' to 'full_name'Index for Employee Name Searches
All problem sets →
CREATE TABLEis the command for "give me a new table with these columns and rules". It's the first SQL on any new project — without tables, there's nothing to INSERT into and nothing to SELECT from.This article is currently in Russian. The full English translation is on the way.