Isys224 database systems : assignment 1 — relational database design

Task Specifications

1.      Task 1 (10 marks) – Logical Database Schema Design

 

Based on the following provided sample solution for the diagnostic assignment, turn it into relational database schema indicating primary key for each table and foreign key if there is any in each table and the primary key that it refers to in another table.

(Note: the figure is small, please enlarge it on the screen or print it)

  

2.      Task 1 [10 marks]-Normalization & DDL

 

Look into the data provided in excel

1.      List all the functional dependencies

2.      Identify all the candidate keys.

3.      Which normal form is this in?

4.      Convert from INF to BCNF (Show the conversion from one NF to another along with the dependencies)

5.      Create tables based on your normalized form[ in Oracle-SQL developer]

 

3.      Task 2 [10 marks]-SQL Queries

 

1.      Write a SQL query that displays the CinemaID, CinamaName and email of Cinema that have more than 2 branches or a branch in the Suburb of ‘Greyjoy’

2.      Write a SQL query that displays BranchAddress, CinemaName and PhoneNumber of the branch that has postcode that starts with 2 or 6

3.      Write a SQL query that displays CinamaName, BranchAddress, Session Date(dd-month-yyyy format), Movie StartTime and date where any French movie is being screened. Sort the result by CinemaName descending

4.      Write a SQL query that displays CinamaName, BranchAddress,  ScreenName, MovieName, YearReleased and Language that screens either a Spanish Movie or a German movie in afternoon or evening session

 

5.      Write a SQL query that displays CinamaName, BranchAddress and the number of screens that are scheduled to screen ‘The Hundred-Foot Journey’

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply