1
GATE CSE 2022
Numerical
+1
-0.33

Consider the relational database with the following four schemas and their respective instances.

Student( $$\underline {sNo} $$ , sName, dNo) Dept( $$\underline {dNo} $$ , dName)

Course( $$\underline {cNo} $$ , cName, dNo) Register( $$\underline {sNo} $$ , $$\underline {cNo} $$ )

GATE CSE 2022 Database Management System - Structured Query Language Question 1 English

SQL Query :

SELECT * FORM Student AS S WHERE NOT EXIST

(SELECT cNo FROM Course WHERE dNo = "D01"

EXCEPT

SELECT cNo FROM Register WHERE sNo = S.sNo)

The number of rows returned by the above SQL query is _____________.

Your input ____
2
GATE CSE 2020
MCQ (Single Correct Answer)
+1
-0.33
Consider a relational database containing the following schemas. GATE CSE 2020 Database Management System - Structured Query Language Question 2 English
The primary key of each table is indicated by underlying 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
A
4
B
5
C
2
D
0
3
GATE CSE 2018
MCQ (Single Correct Answer)
+1
-0.3
Consider the following two tables and four queries in SQL.
Book (isbn, bname), Stock (isbn, copies)
Query 1:
SELECT B.isbn, S.copies
 FROM Book B INNER JOIN Stock S
 ON B.isbn = S.isbn;

Query 2:
SELECT B.isbn, S.copies
 FROM Book B LEFT OUTER JOIN Stock S
 ON B.isbn = S.isbn;
Query 3:
SELECT B.isbn, S.copies
 FROM Book B RIGHT OUTER JOIN Stock S
 ON B.isbn = S.isbn;
Query 4:
SELECT B.isbn, S.copies
 FROM Book B FULL OUTER JOIN Stock S
 ON B.isbn = S.isbn;
Which one of the queries above is certain to have an output that is a superset of the outputs of the other three queries?
A
Query 1
B
Query 2
C
Query 3
D
Query 4
4
GATE CSE 2015 Set 1
MCQ (Single Correct Answer)
+1
-0.3
SELECT operation in SQL is equivalent to
A
the selection operation in relational algebra
B
the selection operation in relational algebra, except that SELECT in SQL retains duplicates
C
the projection operation in relational algebra
D
the projection operation in relational algebra, except that SELECT in SQL retains duplicates
GATE CSE Subjects
Software Engineering
Web Technologies
EXAM MAP
Medical
NEET
Graduate Aptitude Test in Engineering
GATE CSEGATE ECEGATE EEGATE MEGATE CEGATE PIGATE IN
CBSE
Class 12