Question: Consider the SQL Query given below. 1 0 marks SELECT Passenger. ticketno FROM Train, Passenger, Inspector WHERE Train. tno = Inspector.no AND Train.Date = '

Consider the SQL Query given below.
10 marks
SELECT Passenger. ticketno FROM Train, Passenger, Inspector WHERE Train. tno=Inspector.no AND Train.Date='05-07-2023' AND Train.to= Chennai' AND Passenger.name=Inspector.name
a. Convert the following query into relational algebra expressions. 3 marks
b. Reduce the relational algebra expression to an equivalent expression by applying the equivalence rules 3 marks
c. Draw query trees for the two relational algebra expressions. 3 marks
d. State which tree is better in terms of cost of the query execution and why? 1 mark

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!