ExamBank Scot · N5 Computing Science question bank · All N5 Computing Science questions

N5 Computing Science 2024 Question 15

7 marks · Entity-relationship diagrams and keys

Use the information provided to complete the entity‑relationship diagram below by: • identifying any additional key attributes • drawing any missing attributes • drawing the relationship between entities • naming the relationship between the entities. gameID gameName rating Game testerID programmer multiplatform name testerID Tester contactNo State the validation to be applied to the Rating attribute. The Game table is implemented. Some of the data it currently stores is shown below. Game gameID gameName programmer rating testerID multiplatform 378B World Away CodeQueen 12A EX2706 Yes 311H Denta Deet AbdurPSK 15 EX777 No 484D Cupland LindyLoo 12A EX360 No 257P Heat Wave EMC2 15 EX277 Yes 183B Water Rage CodeQueen 15 EX987 Yes 021B Bee‑Hive AcroGymGal 12A EX120 Yes 782C Combat45 AbdurPSK 12A EX2706 No … … … … … … The game ‘Water Rage’ has been reclassified as an 18 rating. The following SQL statement was implemented to make this change. UPDATE Game SET rating = "18" WHERE programmer = "CodeQueen" Explain why the SQL statement above would give an unexpected result. Rewrite the SQL statement to give the expected result. The Games Lab is a video game testing company that programmers can send games to for testing. Each game is allocated to a tester who works on several different games. Testers are based in three offices — Scotland, France and Australia — and only accept games rated 12A, 15 and 18.

Marking scheme

• location in Tester entity • M:1 Cardinality • relationship name • testerID FK and PK Accept other versions of ‘location’ attribute (office, country etc) Ignore additional attributes unless candidate adds additional FK/PK attributes then bullet 4 should not be awarded See example answer below restricted choice Changes all CodeQueen games to 18 Answers may refer to the World Away game also being updated to 18 WHERE gameID = "183B" Quotes not required

Previous question: N5 Computing Science 2024 Question 14

Next question: N5 Computing Science 2024 Question 16