MyMisPal
Phase 2 · Databases

Learn SQL from zero

Twelve short lessons that take you from “what is a database” to joins and normalisation. Each lesson has examples you run with one click and exercises the site grades instantly.

Your progress 0%
0 of 24 exercises solved Progress is saved in this browser only.

Lessons

The practice database

A small company selling hardware and software to clients across the Gulf and the Arab world: departments, employees, customers, products, orders and order lines. It is normalised so you can practise joins like on real systems.

departmentsDepartments
  • dept_idPK
  • name
  • city
employeesEmployees
  • emp_idPK
  • first_name
  • last_name
  • dept_id→ departmentsFK
  • job_title
  • salary
  • hire_date
  • manager_id→ employeesFK
customersCustomers
  • customer_idPK
  • name
  • city
  • country
  • signup_date
productsProducts
  • product_idPK
  • name
  • category
  • price
  • stock
ordersOrders
  • order_idPK
  • customer_id→ customersFK
  • emp_id→ employeesFK
  • order_date
  • status
order_itemsOrder lines
  • order_id→ ordersPK FK
  • product_id→ productsPK FK
  • quantity
  • unit_price
The editor runs a SQLite engine inside your browser: nothing to install. Lessons use standard SQL that also runs in MySQL, and an “In MySQL” box flags any difference.
Spotted a mistake on this page, or have an idea to improve the site?