{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# Tutorial3 - Problem 1 SQL Consider the following database...

This preview shows pages 1–3. Sign up to view the full content.

Problem 1: SQL Consider the following database schema: Band(Band_ID, Band_Name, City, Director, Colors) Festival(Fest_ID, Festival_Name, Location, Fest_Date) Schedule(Schedule_ID, Fest_ID, Band_ID, Perf_Time) Results(Result_ID, Band_ID, Fest_ID, Placement) Write the following queries in SQL: 1. Find the name of all the bands who achieved a "1st" place trophy during the season. 2. Find the name of all the bands performing after 6:00PM at the "Illini Marching Festival" (Use Military time for time comparisons. i.e. 4pm = 16:00) 3. Name the director of any band that performs after October 31st, 2011. (Dates are in the format: DD/MM/YYYY) 4. Find the Placement of every band where one of their school colors is "Green" (Hint: each school has more than 1 color, so a tuple for Colors might read "Red, White, Blue")

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Problem 2: SQL subqueries Consider the following database schema: Speakers(Part_Num, Type, Price, Sold_Indiv) Subwoofer(Part_Num, Lowest_Freq, Peak_Output, Crossover_Value, Driver_Size) CenterChannel(Part_Num, Peak_Output, Mid_Size, High_Size) TowerMains(Part_Num, Peak_Output, Low_Size, Mid_Size, High_Size, Num_Lows) Note that Subwoofers, CenterChannels and TowerMains are all Speakers, as identified by the type field. Also 'Sold_Indiv' is an
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}