Answered step by step
Verified Expert Solution
Question
1 Approved Answer
4. (i) Write the following 2 queries in SQL on the database schema of Figure 1.2 using EXISTS or NOT EXISTS as appropriate (2.5 marks)
4. (i) Write the following 2 queries in SQL on the database schema of Figure 1.2 using EXISTS or NOT EXISTS as appropriate (2.5 marks) (ii) Implement the answering of your 2 queries in 4(i) using Sqlplus and the same database you created in question 1 and modified in earlier question with updates, deletes and inserts, providing your execution and answers to this question in a script file called username_assn3que4. (2.5 marks) (Total for que 4 is 5 marks) (a) Retrieve the album title and copyrightdate of all albums with 2 songs. (b) Retrieve the album title and copyrightdate of all albums that do not have 2 songs Fig 1.2: Schema of the Windsor Music Records database of Figure 1.1 Musician SSN MName Maddress Phone Instrument Iname Musickey Album Aid atitle copyrightdate format Song stitle author Play SSN Iname Fig 1.1: An Example Database State of Windsor Music Records Database Musician MNAME Majid Peters Steven Markel MADDR 4747 Oakwood Dr SSN PHONE 222222222 333333333 Melanie Good 444444444 John Doe 1113331112 1231 Berry Ave 2221113332 423 Walker Rd1231235555 5431 Hefty Lane 6751231231 Instrument INAME Flute Trumpet Guitar Drums MUSICKEY C-Flat E-Flat A-Minor B-Minor Album ATITLE Recovery Revival Welcome AID COPYRIGHTDATE FORMAT 2012-08-08 CD CD CD 2015-09-09 2014-04-03 Song STITLE Hello World Happy All Love Sosa Ball For Me AUTHOR 21 Savage 21 Savage Chief Keef Post Malone Play SSN INAME Drums Flute Guitar Trumpet Guitar Contain:s STITLE Hello World Happy All Love Sosa Ball For Me AID Performs SSN STITLE Hello World Love Sosa Ball For Me Hello World Produces SSN AID
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started