The Structured Query Language
MySQL·2 min read·Jan 1, 2025
The Structured Query Language (SQL) is a programming language designed for managing and manipulating data held in a relational database management system, like MySQL.
It allows users to interact with the database server to perform specific tasks, like retrieving or inserting data, using a series of commands called SQL statements.
When executed, these statements are sent to the database server, which in turn interprets them, processes the data, and returns the result or confirms / invalidates the action.
The types of SQL statements
In SQL, statements can be informally classed in the following sublanguages:
-
The data definition language (DDL) is used to define, modify, and manage database objects, such as tables, indices, and users.
-
The data manipulation language (DML) is used to manage and manipulate data within the database.
-
The data query language (DQL) is used to retrieve information or data from database tables based on specified criteria.
-
The data control language (DCL) is used to ensure the security of the database and control its access by granting and revoking permissions and privileges to users.