dcf.cymru stimulus sheet · Computer Science · Year 9

The school device loan list

This is one big spreadsheet, kept by hand. Your job in the lesson is to work out why it keeps going wrong and redesign it as a proper database.

Cover teacher — how to use this sheet

Print one per pair. It is deliberately messy. Pupils do not have to fix the data — they have to spot the problems and design a better structure on the worksheet. No computers are needed.

What the office told the technician

"Every time a pupil borrows a Chromebook we add a row. It is up to 900 rows now. Two people type in the names, the dates are in whatever format the typist likes, and last week we could not tell whether asset CB-0042 was out with one pupil or three. When a pupil changes form group we have to hunt through the whole sheet."

Sheet: device_loans_2025.xlsx — first 10 rows

No. Pupil name Form Pupil DOB Asset tag Model Replace cost Out Due Back Charger?
1Elin Prys9B12/03/2011CB-0042Acer Chromebook 314£215.0015/09/202529/09/202526/09/2025yes
2Rhys Morgan-Hughes9A02/11/2010CB-0017Acer Chromebook 314£215.0015/09/202529/09/202530/09/2025yes
3elin prys9B12/03/2011CB-0108HP Chromebook 11 G9£189.991st Oct15th Octno
4Seren Bowen9C24/07/2011CB-0042Acer Chromebook 314£21502/10/202516/10/202514/10/2025y
5Rhys Morgan Hughes9A02/11/2010CB-0042Acer Chromebok 314£215.0002/10/202516/10/202509/10/2025yes
6Osian Lloyd9B30/01/2011CB-0091Lenovo 300e Chromebook£232.5006/10/202520/10/202520/10/2025yes
7Seren Bowen9D24/07/2011CB-0017Acer Chromebook 314£215.0007/10/202521/10/2025no
8Cadi Edwards9A18/05/2011CB-0108HP Chromebook 11 G9£189.9920/10/202503/11/202503/11/2025yes
9Osian Lloyd9B30/01/2011CB-0091Lenovo 300e Chromebook£232.5005/11/202519/11/2025yes
10Ffion Davies9C09/09/2011CB-0055Acer Chromebook 314£215.0005/11/202519/11/202518/11/2025Y

Three complaints from the office, word for word

Data types you may use in your design

Pick the narrowest type that fits the data. A date stored as text cannot be sorted or subtracted.

TypeHoldsExample value
INTEGERWhole numbers, including ID numbers1042
VARCHAR(n)Text up to n charactersVARCHAR(40) — "Lenovo 300e Chromebook"
CHAR(n)Text that is always exactly n charactersCHAR(7) — "CB-0042"
DATEA calendar date, sortable and subtractable2025-10-02
DECIMAL(p,s)Exact money, p digits with s after the pointDECIMAL(7,2) — 215.00
BOOLEANTrue or false onlyTRUE