What you will learn
Almost every app and website keeps its data in a database, and SQL (often said "sequel") is how you get it back out. It is one of the most useful skills for anyone who works with data: analysts, marketers, developers and spreadsheet power users alike.
- Reading data: choose columns, filter rows and sort results.
- Searching: match text patterns, lists and ranges.
- Summarizing: count, add up and average, per group.
- Combining tables: join related tables into one result.
- Changing data: insert, update and delete rows.
The practice database
All lessons use the same small database of a shop, with three tables: customers, products and orders. It runs inside your browser using SQLite, the most widely used database engine in the world. Every time you press Run you get a fresh copy, so you can experiment freely.
How the lessons work
Type a query and press Run (or Ctrl+Enter) to see the rows it returns. Check My Code compares your result with the expected one, so any query that returns the right rows passes. You can practice more in the Code Playground, which has the same database.
Frequently asked questions
Is this SQL course free?
Yes. Every lesson is free, with no account and no limits.
Do I need to install a database?
No. A real SQLite database runs inside the page. The first run downloads the engine, which is under 1 MB.
Which kind of SQL is taught?
The lessons use SQLite and stick to standard SQL that also works in MySQL, PostgreSQL and SQL Server. Small differences between databases mostly show up in advanced features.
Can I break the practice database?
No. Each run starts from a fresh copy, so deleting or changing rows only lasts for that run.
How are my answers checked?
Your query result is compared with the expected rows. There is usually more than one correct way to write a query, and all of them pass.
Do I get a certificate?
Yes. Finish every lesson to unlock a certificate of completion with your name on it. It is a personal record, not an accredited qualification.