8 lessons
SQL DDL: creating tables and choosing data types
CREATE TABLE, ALTER TABLE, DROP TABLE, and a practical tour of the SQL data types you'll actually use, tying back to the domains from Module 2 and 3.
SQL DML: INSERT, UPDATE, and DELETE
Adding, changing, and removing rows safely, and why the WHERE clause is the single most important word in this entire lesson.
SELECT, filtering, and sorting in depth
The full anatomy of a SELECT statement, pattern matching, range and set conditions, NULL handling, and sorting query results.
Aggregation and grouping
COUNT, SUM, AVG, MIN, MAX, GROUP BY, and the crucial difference between filtering rows with WHERE and filtering groups with HAVING.
SQL joins in practice
INNER JOIN, LEFT/RIGHT/FULL OUTER JOIN, self joins, and CROSS JOIN written as real SQL, connecting directly back to the relational algebra join theory.
Subqueries and set operations
Scalar, row, and correlated subqueries, EXISTS/NOT EXISTS for expressing "for all" logic, and UNION/INTERSECT/EXCEPT.
Window functions and common table expressions
RANK/ROW_NUMBER/running totals with the OVER clause, and CTEs (including recursive CTEs) for readable, composable queries.
Views, constraints, and triggers
CREATE VIEW as a saved query, the full set of SQL constraint keywords, and triggers for automatic actions on data changes.