Skip to content
Related Articles
Open in App
Not now

Related Articles

GATE | GATE-CS-2005 | Question 77

Improve Article
Save Article
  • Last Updated : 28 Jun, 2021
Improve Article
Save Article

The relation book (title, price) contains the titles and prices of different books. Assuming that no two books have the same price, what does the following SQL query list?

  select title
  from book as B
  where (select count(*)
     from book as T
     where T.price > B.price) < 5 

(A) Titles of the four most expensive books
(B) Title of the fifth most inexpensive book
(C) Title of the fifth most expensive bookTitles of the five most expensive books
(D) Titles of the five most expensive books

Answer: (D)

Explanation: See Question 3 of

Quiz of this Question

My Personal Notes arrow_drop_up
Related Articles

Start Your Coding Journey Now!