SQL: Querying, Modelling and Running a Database
Exit

Lesson 7 of 14 · Querying and modelling

Subqueries, CTEs (WITH) and set operations (UNION, INTERSECT, EXCEPT)

55 min Python 3.12 (Debian, git, pip)

Objective

Answer multi-step questions — "the products more expensive than average", "the orders above the average basket", "the cities to follow up" — by nesting queries, splitting them with WITH and combining results with UNION, INTERSECT and EXCEPT.

This lesson is part of the full course

Unlock SQL: Querying, Modelling and Running a Database to read every lesson, do the exercises, access the simulations and earn your certificate.

Already enrolled? Log in.