SQL for the age of AI
Atterna SQL: write it, read it, check it.
Try it · 30 seconds · from Atterna’s practice
| orders.id | amount | items in the order |
|---|---|---|
| 1 | €50 | 3 |
| 2 | €30 | 1 |
SELECT SUM(o.amount) FROM orders o JOIN items i ON i.order_id = o.id;
What does this query return?
Preparing the practice…
An AI assistant writes a query in seconds. It also writes queries that double-count after a join, drop people in a LEFT JOIN and average away a skew — and they all run. Atterna SQL trains the part it can’t do for you: knowing what a query really counts, and what the number means.
Ways to practise SQL at Atterna
What makes it different
- Real mess, not toy tables: cancelled orders, refunds and baskets split between several sellers.
- Every query is also run on a second dataset with different numbers, so a query that fits one by accident is caught.
- Each exercise asks what the number means for a decision, the part an AI cannot answer for you.
SQL terms, with the trap in each
- Primary key
- NULL
- GROUP BY
- WHERE vs HAVING
- INNER JOIN
- LEFT JOIN
- Join fan-out
- COUNT(DISTINCT …)
- Window function
- CTE
- Grain
FAQ
What is Atterna SQL?
The SQL practice of Atterna, a learning product for data analysis. You write and read SQL on a fictional marketplace, starting from zero in Start or on work requests in Cases, and learn to check SQL that someone — or something — else wrote.
Is Atterna SQL free?
The first two days of Start, case 1 of Cases, the SQL interview questions, the JOIN practice, the level test and the AI answer checker are free with no account. SQL is free: all 10 days of Start with a free account. You pay only for practice: case rounds (€19) and Meridian (€59).
Do I need to install anything?
No. Queries run in your browser on synthetic marketplace data.
Is Atterna related to Amazon Athena?
No. Amazon Athena is AWS’s serverless query service. Atterna is an independent place to learn and practise SQL and data analysis; the names only look alike.