GATE CS 2015, set 3 · Question 29 · Databases · Multiple choice (MCQ) · 1 mark · −1/3 for a wrong answer
Consider the following relation
Cinema(theater, address, capacity)
Which of the following options will be needed at the end of the SQL query
SELECT P1.address FROM Cinema P1
such that it always finds the addresses of theaters with maximum capacity?
- (A) WHERE P1.capacity >= All (select P2.capacity from Cinema P2)
- (B) WHERE P1.capacity >= Any (select P2.capacity from Cinema P2)
- (C) WHERE P1.capacity > All (select max(P2.capacity) from Cinema P2)
- (D) WHERE P1.capacity > Any (select max(P2.capacity) from Cinema P2)
Answer
Answer (A)
Answer from the official GATE CS 2015 answer key.
The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes