Question 4 The Independent Electoral Commission publishes election results as a spreadsheet. The columns are: Province,
Posted: Fri Jul 01, 2022 5:43 am
Question 4 The Independent Electoral Commission publishes election results as a spreadsheet. The columns are: Province, Ward name, Ward number, Party, Provincial party leader, Number of votes (num- ber of votes the party got in that ward). Within each province the ward name is unique. The ward number is unique across the whole country. a) Give the SQL code to create a table that would store this data in the format given. (4 marks) b) Give the SQL code to find how many votes the Pastafarian Party won in the Linguini ward in Gauteng. (3 marks) c) Give the SQL code to find how many votes the Pastafarian Party won across country. the whole (1 marks) d) Give the SQL code to find how many wards the Pastafarian Party received more votes than the National Pasta Front. (3 marks) (1 marks) (6 marks) compared to the (2 marks) [Total Marks 20] e) What normal form is the table in? Explain. f) Give the declarations necessary to store this data in third normal form. g) Give one advantage and one disadvantage of the normalised database simpler version defined above in Question 4a.