Loading Data Driven Insights
Preparing your learning content.
Preparing your learning content.
A beginner-friendly guide to Data Definition Language, common DDL commands, and how DDL is used to create and manage database structure.
On this page
Jump to a lesson section
DDL stands for Data Definition Language.
It is the part of SQL used to create, change, and manage the structure of a database.
DDL commands are used before and during database design. They help define how your database is built.
DDL and DML both belong to SQL, but they solve different problems.
DDL works with database structure. DML works with the data stored inside that structure.
DDL changes the design of the database.
DML works with the data stored inside the database.
A common DDL command is CREATE TABLE. It creates a new table and defines its columns and data types.
CREATE TABLE Employees (
employee_id INT,
employee_name VARCHAR(100),
department VARCHAR(50),
salary DECIMAL(10, 2)
);
The most common DDL commands are used to create, change, clear, or remove database objects.
Before storing data, you need DDL to create the tables and objects that will hold that data.
SQL Roadmap Progress
Topic 11 of 111
10% complete
Next in SQL Roadmap
Continue with the next SQL topic in the recommended roadmap order.
Continue learning →