GATEverse
← GATE CSE 2006

Q67

MCQ2 marks, −0.5

Consider the relation account (customer, balance) where the customer is a primary key and there are no null values. We would like to rank customers according to decreasing balance. The customer with the largest balance gets rank 1.1. Ties are not broke but ranks are skipped: if exactly two customers have the largest balance they each get rank 11 and rank 22 is not assigned. Query1:\text{Query1:} select A.customer, count(B.customer) from account A, account B where A.balance <=B.balance group by A.customer Query2:\text{Query2:} select A.customer, 1+count(B.customer) from account A, account B where A.balance < B.balance group by A.customer Consider these statements about Query11 and Query2.2. Which two of the above statements are correct? 22 and 55 11 and 33 11 and 44 33 and 55

Sign in to save attempts.

Loading…