Gradient LabSign up free

Home / GATE DA / 2026 / Q.60

GATE DA 2026, Q.60: Accounts with at least as many richer as poorer accounts

DatabasesCorrelated subqueries2 marksNumerical answer

The question

Account(AccNo, Balance) = (A1, 5000), (A2, 5000), (A3, 10000), (A4, 15000), (A5, 18000). How many rows does the query return?

SELECT AccNo FROM Account AS A
WHERE (SELECT COUNT(*) FROM Account AS B
       WHERE A.Balance < B.Balance) >=
      (SELECT COUNT(*) FROM Account AS C
       WHERE A.Balance > C.Balance)

Checking your access…

Source: official GATE DA 2026 question paper and answer key (IIT Guwahati). The question is lightly reworded; every number and option is kept.