Gate2020 cs Q27

0. Consider a relational database containing the following schemas.

The primary key of each table is indicated by underlining the constituent fields
SELECT s.sno, s.sname
FROM Suppliers s, Catalogue c
WHERE s.sno = c.sno AND
Cost > (SELECT AVG (cost)
FROM Catalogue
WHERE pno = ‘P4’
GROUP BY pno);
The number of rows returned by the above SQL query is

  • Option : B
  • Explanation :

    Therefore 4 rows returned by the above query.
Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *