A SQL statement for retrieving data from a database.
The basic SQL syntax for extracting rows and columns matching a condition from a table, used together with clauses such as WHERE, GROUP BY, and ORDER BY. The logical execution order is FROM -> WHERE -> GROUP BY -> HAVING -> SELECT -> ORDER BY, which differs from the order it's written in (starting with SELECT) -- something that affects how aliases can be used.
© 2026 ITBGM