Author(s): Muaaz

Originally published on Towards AI.

SQL (Structured Query Language) is a language used to interact with relational databases that store structured data. It is primarily used to perform operations such as querying, inserting, updating, and deleting data.

SQL operations are mainly categorized into two broad groups: DDL (Data Definition Language), which defines database structure, and DML (Data Manipulation Language), which is used to interact with and modify data. In practice, SELECT queries are often included under DML, although they are sometimes referred to separately as DQL (Data Query Language).

First, we will explore DDL commands, how they work, and their use cases.