SQL sandbox
Read-only in-browser SQL playground seeded with a small example schema (users, orders, products). Run queries against it to practice JOINs, aggregations, and subqueries without setting up a database. Stub — not implemented yet.
Input parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| query | string | Yes | The SQL statement to execute. Read-only — DDL/DML statements are rejected. |
| dataset | string | No | Which seeded schema to query. Each ships with deterministic sample data. |
| show_query_plan | boolean | No | If true, return the EXPLAIN output alongside the result rows. |
Placeholder tool descriptor for a sandboxed SQL execution surface. Pairs with the sql-inner-vs-left-join and sql-group-by-and-having notes — students read the note, then immediately run the example queries against a seeded schema without spinning up Postgres locally.
The study blueprint (week 12) will render this descriptor through study/tool.html. Implementation will likely use sql.js (SQLite compiled to WASM) running entirely client-side so there's no server-side query execution to lock down — the sandbox property comes for free since the database lives in the browser tab.