Gradient LabSign up free

Home / GATE DA / 2025 / Q.33

GATE DA 2025, Q.33: Loans above the SR Nagar maximum

DatabasesSubqueries with MAX1 markNumerical answerFree

The question

Loan(loan_number, branch_name, amount): (L11, Banjara Hills, 90000), (L14, Kondapur, 50000), (L15, SR Nagar, 40000), (L22, SR Nagar, 25000), (L23, Balanagar, 80000), (L25, Kondapur, 70000), (L19, SR Nagar, 65000). How many rows does the query return?

SELECT L1.loan_number
FROM Loan L1
WHERE L1.amount > (SELECT MAX(L2.amount)
                   FROM Loan L2
                   WHERE L2.branch_name = 'SR Nagar');

Watch it solved

Solve it step by step

  1. Subquery. Largest SR Nagar amount = 65000.
  2. Filter. Amounts above 65000: 90000, 80000, 70000.
  3. Answer. 3 rows (L11, L23, L25).

Answer: 3

Official IIT Roorkee answer key: 3.

Common mistake. Using the SR Nagar minimum or average instead of the maximum.

Remember. x > MAX(set) means x beats every member of the set.

Want every question solved? The past-paper pack has all 195 questions from 2024, 2025 and 2026 for ₹499. The cheat sheet pack has 23 printable sheets for ₹399.

See the past-paper pack See the cheat sheets

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