Question 1 Report
A school creates a database to store details about its computing equipment. Part of the database is shown below.
| AssetID | DeviceType | RoomNumber | PurchaseDate | WarrantyExpiry | Working |
|---|---|---|---|---|---|
| A2001 | Laptop | 14 | 12/09/2022 | 12/09/2025 | Yes |
| A2002 | Printer | 7 | 03/04/2021 | 03/04/2024 | Yes |
| A2003 | Projector | 14 | 18/01/2023 | 18/01/2026 | No |
| A2004 | Laptop | 22 | 05/11/2020 | 05/11/2023 | Yes |
| A2005 | Desktop | 7 | 22/06/2022 | 22/06/2025 | Yes |
(a) State the data type for each of the following fields:
(i) DeviceType [1]
(ii) RoomNumber [1]
(iii) PurchaseDate [1]
(iv) Working [1]
(b) The school wants to find all working devices in Room 14. Write the search criteria. [2]
(c) Describe one validation check that could be applied to the RoomNumber field. [2]
(a) Data types for each field:
(b) Search criteria to find all working devices in Room 14:
RoomNumber = 14 [1] AND Working = "Yes" [1]
Both conditions must be true. From the sample data, this would return the Laptop (A2001) and the Projector (A2003) would be excluded because Working = "No".
(c) One validation check for the RoomNumber field:
Range check: The room number must fall within a valid range, for example between 1 and 50. [1] This prevents a user from accidentally entering a room number that does not exist in the school building, such as 999 or a negative number. [1]
Everything you need to excel in your exams