Question: Create a database called music. Create a table called bandinfo with the following columns. Make sure to choose optimal data type for each. Insert
Create a database called music. Create a table called bandinfo with the following columns. Make sure to choose optimal data type for each. Insert 20 records into the table. Pick your favourite bands and favourite genre of music. - Band Name - Formation Year Current Status (Active or Inactive) Base City Base Country - Number of Releases - Genre 2- (25%) - Create a second table called bandrecognition with the following columns. Make sure to choose optimal data type for each. Insert 20 rows. Make sure band names in this table have a corresponding band name in the bandinfo table. - - Number of Band Members - Band Name Award Nomination ("N" for nominated; "A" for awarded) Year 3- (25%) - Alter the bandinfo table. Add a column called releases. This column will contain a JSON document containing with the list of releases, type of release, release year and release title. See JSON example provided. Choose a number of bands (a minimum of 5) and create a JSON document to list releases. 4- (25%) - Create a fourth table called bandmembers with the following columns: - - Band Name - Last Name First Name Role Start Year End Year Select a set of bands (a minimum of 5) and add the band members to this table. For this table we need to set up automatic history - sometimes called history tables. The purpose of history tables is to keep track of changes made to the table so you can run - what is called - an "AS OF" query. Read about this. You'll understand why we want to use this capability for this table given band members can change quite a bit for bands. If you are using Db2 - this is what you want: https://www.ibm.com/docs/en/db2-warehouse?topic=tables- application-period-temporal If you are using Oracle - this is what you want: https://docs.oracle.com/database/121/VLDBG/GUID-AF78C832-516A- 4686-9DDF-CE12597F7723.htm#VLDBG14127 If you are using Microsoft SQLServer- this is what you want: https://learn.microsoft.com/en-us/sql/relational- databases/tables/temporal-tables?view=sql-server-ver16
Step by Step Solution
There are 3 Steps involved in it
It looks like youve shared a complex multipart database assignment with various steps Heres the outline and SQL statements required to complete each part based on the images provided Since the specifi... View full answer
Get step-by-step solutions from verified subject matter experts
