NewThe ManyPI MCP Server is now live

SQL sandbox with tasks that check themselves

A real SQLite database in the browser with three datasets, twelve tasks that check the learner's answer, and links that share a query without storing anything.

Web toolBachelor +2CC BY 4.0

What you will learn

  • Write queries across several tables with JOIN
  • Group and aggregate data with GROUP BY and HAVING
  • Use a subquery
  • Create a table and fill it with INSERT

What it is

A workspace for learning SQL that needs nothing but a browser. It runs SQLite, the database engine used in phones and browsers, compiled to WebAssembly.

  • Three databases: an office supplies shop (customers, products, orders and order items), school scores (students, courses and scores), and an empty database for creating your own tables.

  • Twelve tasks from a first WHERE to joins across three tables and a subquery. "Check my query" compares the learner's result with the expected one, row by row. A hint and the solution are one click away, never shown unasked.

  • The schema of every table, with a click to insert a table or column name.

Safe for school use

  • Everything runs on the learner's device. Queries are never sent to a server, and nothing is stored.

  • A query that runs too long is stopped after a few seconds and the database is reset, so a mistake cannot freeze the tab.

  • No account, no cookies needed, no personal data asked for.

Sharing without storing

"Share" turns the dataset, the query and the open task into a link. The information sits in the part of the address after #, which browsers never send to a server. A teacher can prepare a starting query and post the link; a shared query is only run when the learner presses Run.

Ideas for class

  1. Warm-up: everyone opens the shop database and runs SELECT * FROM customers to read the table together.

  2. Pairs: work through the shop tasks; the first pair with all six solved explains task 5 (customers without orders) to the class.

  3. Build your own: in the empty database, each group designs a table for something from school life (lending library, sports club) and writes three questions for another group.

Reuse this material

CC BY 4.0

You may copy, adapt and share it, also commercially, as long as you credit ManyPI and link back.

"SQL sandbox with tasks that check themselves" by ManyPI (https://manypi.com/edu/sql-sandbox), licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/)