· intermediate
Intermediate SQL
Ask questions that need a query inside a query. Categorise rows with CASE, filter against a computed set, and combine results that come from different places.
Written in house, from the work rather than from a syllabus. Every example is one we would use ourselves, and every exercise is checked against the same engine that grades your answer.
What you’ll learn
- Categorise and reshape rows with CASE
- Filter against a value or list produced by another query
- Use a subquery as a derived table in FROM
- Tell a correlated subquery from an independent one and know the cost
- Choose between IN, EXISTS and a join for the same question
- Combine result sets with UNION, INTERSECT and EXCEPT
Before you start
- · SQL Foundations and Joining Data in SQL
- · Comfort with GROUP BY and the aggregate functions