SQL For Absolute Beginners
Go from zero to writing real queries that filter, join, group, and safely change data in a database.
This course is for members
$9 unlocks every course in the library, this one included, plus a credit to build a topic of your own and at least 10 new courses every month.
What you will learn about SQL for Absolute Beginners
The 7-day sprint
- Tables, Rows, and Your First SELECT. A relational database stores data in tables made of named columns and unordered rows, and
SELECT ... FROMasks one of those tables for the columns you want. - Filtering Rows With WHERE.
WHEREtests each row against a condition and keeps only the rows for which the condition is true. - Sorting, Limiting, and Naming Results.
ORDER BYdecides the order of the returned rows,LIMITcuts the result to a size,DISTINCTremoves duplicate rows, andASrenames a column in the output. - Counting and Grouping. Aggregate functions collapse many rows into one number, and
GROUP BYruns that collapse once per group instead of once for the whole table. - Joining Two Tables. A join pairs rows from two tables using a matching column, and the join type decides what happens to rows that find no partner.
- Subqueries and Common Table Expressions. A query can be used as an input to another query, either inline as a subquery or named up front with
WITH, so complex questions become a chain of small ones. - Changing Data Safely.
INSERT,UPDATE, andDELETEchange what is stored, and a transaction lets you undo a mistake before it becomes permanent.
The 80/20: the 6 concepts that matter most
- The SELECT skeleton and its logical order
- Filtering with WHERE
- Joins and keys
- Aggregates and GROUP BY
- NULL and three valued logic
- Breaking work into steps with CTEs
The core idea, explained like you are 5
Every SQL query takes one or more tables of rows, keeps and reshapes only what you asked for, and hands you back a brand new table, without you ever telling the computer how to go find it.
Then the quiz and the ladder
10 questions that correct you when you are wrong, and beginner, intermediate, advanced levels, each with a practical exercise.
Created Sep 12, 2026. No mistakes have been reported by learners.
Written from these sources
- The SQL Standard - ISO/IEC 9075:2023 (ANSI X3.135) - The ANSI Blog, blog.ansi.org. day 1 and expert stage, SQL standard history and 2023 revision.
- ISO/IEC 9075-1:2023 - Information technology — Database languages SQL — Part 1: Framework (SQL/Framework), iso.org. expert stage, ISO/IEC 9075 framework and semantics.
- PostgreSQL: Documentation: 18: SELECT, postgresql.org. expert stage, output expression evaluation versus ORDER BY and LIMIT.
- PostgreSQL: Documentation: 18: 9.1. Logical Operators, postgresql.org. day 2 and NULL concept, three valued logic.
- PostgreSQL: Documentation: 10: 4.2. Value Expressions, postgresql.org. expert stage, evaluation order caveats and CASE limits.
- A Visual Explanation of SQLite Joins, sqlitetutorial.net. day 5, inner, left, and cross join behavior.
- SQLite JOINs: INNER, LEFT, CROSS, and FULL JOIN Workarounds | DbSchema, dbschema.com. day 5, RIGHT JOIN added in SQLite 3.39.
- PostgreSQL: Documentation: 18: 2.6. Joins Between Tables, postgresql.org. join explanation in the intermediate level.
- PostgreSQL: Documentation: 18: 7.2. Table Expressions, postgresql.org. FROM, WHERE, GROUP BY pipeline and cross join warning.
- SELECT (Transact-SQL) - SQL Server | Microsoft Learn, learn.microsoft.com. alias binding order used in quiz question 10.
- SELECT - ORDER BY clause (Transact-SQL), learn.microsoft.com. ORDER BY default and unguaranteed row order.
- MySQL :: MySQL 8.0 Reference Manual :: 15.2.13 SELECT Statement, dev.mysql.com. HAVING versus WHERE rules in quiz question 7.
- Modern SQL: Three-Valued Logic (3VL) — Purpose, Benefits and Special Cases, modern-sql.com. null and unknown logic in the advanced level.
- Structured Query Language/NULLs and the Three Valued Logic - Wikibooks, open books for an open world, en.wikibooks.org. nulls grouped as one in GROUP BY and DISTINCT.
- NULL values represent in SQLite | Abdul Wahab Junaid, awjunaid.com. aggregates ignoring nulls in quiz question 4.