COMP3311 20T3 The University of New South Wales Database Systems
COMP3311 Database Systems
20T3
[Instructions] [Notes] [Database] [Course Website] [Cheat Sheets]
[Q1] [Q2] [Q3] [Q4] [Q5] [Q6] [Q7] [Q8] [Q9] [Q10] [Q11] [Q12]
Question 2 (6 marks)
Write an SQL view that gives the names of all players who have scored more than one goal that is rated as “amazing”.
Each tuple in the result should also include the number of amazing goals scored.
Instructions:
Work on this question in the work/q2/ directory
Define a view q2(player,ngoals) in the file q2.sql
Also, place any additional views used by q2 in this file
Additional views must be placed before the q2 definition
Load it into your database using: psql footy -f q2.sql Sample output is in the file: tests/01.expected
Test it via: select * from q2 order by player;
Check it using: sh check q2 in the q2 directory
Submit it using: give cs3311 sample_q2 q2.sql or Webcms3
End of Question