Transactions and ACID – OCR A Level Computer Science lesson (H446)
Students learn to explain what a transaction is and how each ACID property keeps data correct, applied to a scenario.
Lesson 6 of 14 in unit 13.1 Databases, SQL and Floating Point, taught in Year 13, Autumn 1. It answers one big question: How can a database change several records without ever being half-done?
By the end, students can explain what a transaction is and how each ACID property keeps data correct, applied to a scenario.
- The Build (the main task)
- Explain how each of the four ACID properties protects Saltmere Ferries' database when a passenger moves their car booking from one sailing to another (8 marks).
- Support version
- A four-row ACID table with the property names, a one-line meaning for each and an empty 'what it means for the booking move' column; the first row is done as a model.
- Challenge
- Explain why the booking move must be one transaction rather than two separate updates, using what happens if the server fails between them.
- Real-world link
- A Saltmere passenger moves their car from the Friday to the Saturday sailing.
- Key words
- Transaction, ACID and Integrity, each with a definition, an icon and a common mix-up on the key vocabulary slide.
- Misconceptions it tackles
- “A transaction is a payment, so only money changes need ACID”; “If the server fails halfway through, the changes already made are kept and the rest can be done later”.
- OCR H446 specification
- 1.3.2 (f).
Every lesson follows the same Code & Commerce structure: a Bell Task recall starter, key vocabulary with definitions and icons, short teaching chunks with a check before pupils move on, The Build (one main task), challenge questions that get harder, and an exit question. Answers reveal one at a time on the slides, and everything is editable PowerPoint and Word.
Students can do it all on paper.
Also sold in the Databases, SQL and Floating Point unit bundle, which includes the medium term plan, and in the full-year and complete-course bundles.
An independent resource written for OCR A Level Computer Science (H446). It is not endorsed by OCR or Cambridge University Press & Assessment. Programming project (NEA) lessons teach general skills on a made-up example project and give supervised time, within JCQ's rules on the help a centre may give.
What's included
- Slide deck (PowerPoint)
- Lesson plan (Word)
- Worksheet (Word)
- Support worksheet with scaffolds (Word)
- Single-teacher licence: use and adapt it with your own classes
More for A Level Computer Science
See allStudents learn to write and interpret SQL queries using SELECT, FROM, WHERE (with AND, OR) and ORDER BY on one table.
Free sample lessonStudents learn to write SQL that joins two tables on a foreign key and filters records with LIKE and wildcards.
Students learn to write INSERT INTO, UPDATE, DELETE and DROP statements and predict exactly which records each one changes.
Written for the specifications named. Not endorsed by or affiliated with any exam board.