Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Instructions . When writing a query, write the query in a way that it would work over all possible database instances and not just for

image text in transcribed

Instructions . When writing a query, write the query in a way that it would work over all possible database instances and not just for the given example instance! Consider the following database schema and example instance for a race car database: Good luck Question IV 15 Points) Write a relational algebra expression that returns the female racer's name, born before 1962 with the highest race time. Car Racer A ID Name 1 Sam 2 Suzan 3 Alice Gender Birth_yead M 1984 F 1982 F 1980 CID Manufacturer Horsepower Nbr of cylinder C1 Mercedes 1200 6 s 02 Ferrari 2400 8 03 Mercedes 800 4 Result Race Result IDC_ID R_ID A ID Time R1_1 C1R11 400 R1 2 c2 R1 2 600 R1 3 03 R13 375 R ID Type Location R1 F1 UK R2 Rallycross Portugal R3 F1 USA Sponsor RID R1 R1 R2 CID Sponsor C1 Motorola Pepsi Michelin Question V 15 Points) Write a relational algebra expression that returns the racer's name and associated ncc sponsor that crave a 'Mercedes car during at cast one of their races. Schema: Racer: (A ID, Name, Gender, Birth year) Race (R ID, Type, Location) Result Result.ID, C_ID, A_ID, R_ID, Time) C_ID is a foreign key for car and A_ID is torcign key for Racer and R_ID is a foreign key for Race Sponsor (R ID.C ID, Sponsor) Car (C_ID, Make, Horsepower Question VI 14 points) Write a relational algebra expression that return the winner name in each race. The winner is the racer that finishes the race in least time

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

OCA Oracle Database SQL Exam Guide Exam 1Z0-071

Authors: Steve O'Hearn

1st Edition

1259585492, 978-1259585494

More Books

Students also viewed these Databases questions