Question: SELECT S . sid FROM Sailors S , Boats B , Reserves R WHERE S . sid = R . sid AND R . bid

SELECT S.sid
FROM Sailors S, Boats B, Reserves R
WHERE S.sid=R.sid AND R.bid=B.bid AND B.color=red
UNION
SELECT S.sid
FROM Sailors S, Boats B, Reserves R
WHERE S.sid=R.sid AND R.bid=B.bid AND B.color=green
Which of the following is equivalent with the above query?
SELECT S.sid
FROM Sailors S, Boats B, Reserves R
WHERE S.sid=R.sid AND R.bid=B.bid AND B.color=red OR B.color=green
WHERE S.sid=R.sid AND R.bid=B.bid AND (B.color=red OR B.color=green)
WHERE S.sid=R.sid AND R.bid=B.bid AND B.color=red AND B.color=green
WHERE S.sid=R.sid AND R.bid=B.bid AND B.color <>blue
None of the above

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!