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

N5 Computing Science 2021 Question 14

4 marks · SQL SELECT

The SQL query below is executed. SELECT name, address, phoneNumber FROM restaurant WHERE (foodType = "Italian" OR foodType = "French") AND starRating > 1 AND starRating < 5 ORDER BY averagePrice ASC Describe the output that would be listed under the headings name, address and phoneNumber when the above query is executed. State which SQL operation would be required to change the phone number of a restaurant in the database. A database is used to store data about restaurants. This includes the type of food they serve, the average price of a meal and a rating of 1, 2, 3, 4 or 5 stars.

Marking scheme

One mark each for • restaurants which serve either Italian or French food will be listed • restaurants with a rating of 2,3 or 4 will be listed • the displayed restaurants will be sorted by average price from lowest to highest UPDATE

Previous question: N5 Computing Science 2021 Question 13

Next question: N5 Computing Science 2021 Question 15