Lesson Plan

Lesson Plan
Grade: Date: 17/01/2026
Subject: Computer Science
Lesson Topic: Understand and write basic SQL queries including SELECT, WHERE, AND, OR, ORDER BY
Learning Objective/s:
  • Describe the role of a relational database and its table structure.
  • Write SELECT statements to retrieve specific columns from a table.
  • Apply WHERE clauses with comparison operators to filter rows.
  • Combine multiple conditions using AND, OR and parentheses.
  • Sort query results with ORDER BY using ASC and DESC.
Materials Needed:
  • Projector and screen
  • Computer lab with SQL IDE (e.g., MySQL Workbench)
  • Printed handout of the Students table
  • Worksheet with practice query questions
  • Whiteboard and markers
  • Internet access for reference
Introduction:

Begin with a quick poll: “Where have you seen databases in everyday life?” Connect this to prior lessons on data storage. Explain that by the end of the session students will be able to craft basic SQL queries to retrieve and sort data, meeting today’s success criteria.

Lesson Structure:
  1. Do‑now (5'): Students list three real‑world examples of databases on a sticky note.
  2. Mini‑lecture (10'): Review SELECT syntax and demonstrate retrieving all columns vs. specific columns.
  3. Demonstration (10'): Introduce WHERE clause, comparison operators, and string quoting.
  4. Guided practice (10'): Model combining conditions with AND, OR, and parentheses using the Students table.
  5. Independent activity (15'): Students complete worksheet queries (SELECT, WHERE, AND/OR, ORDER BY) while teacher circulates for support.
  6. Review & exit ticket (5'): Quick recap of key concepts; students write one query they found challenging and a brief explanation.
Conclusion:

Summarise how each clause (SELECT, WHERE, AND/OR, ORDER BY) shapes the result set. Collect exit tickets to gauge understanding and assign a homework task: write five new queries on the provided Students table, including at least one using both AND and OR.