Which SQL operator returns only the rows that are common and present in the outputs of both executing SELECT queries? MCQ with Answer and Explanation

Which SQL operator returns only the rows that are common and present in the outputs of both executing SELECT queries?
A. INTERSECT
B. JOIN
C. EXCEPT / MINUS
D. UNION
Answer: Option A
Solution (By JKSSB Mock Tests)
The INTERSECT operator returns only the distinct rows that appear in the result sets of both SELECT statements.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Database Management System (DBMS) Questions

Question #1
Which of the following is a valid SQL string function?
A. REPLACE
B. All of the above
C. CONCAT
D. SUBSTRING

Correct Answer: Option B


Explanation:
SUBSTRING, CONCAT, and REPLACE are common string functions in SQL.

This question belongs to: Computer Database Management System (DBMS)
Question #2
Which of the following is true about a surrogate key?
A. It is a composite key
B. It is a natural key derived from the data
C. It is a foreign key
D. It is an artificial key, usually an auto-increment integer, with no business meaning

Correct Answer: Option D


Explanation:
A surrogate key is a system-generated unique identifier, typically numeric, that has no business significance.

This question belongs to: Computer Database Management System (DBMS)
Question #3
What is a primary key in a database table?
A. A key that uniquely identifies each row in a table
B. A key that can contain duplicate values
C. A key that is always numeric
D. A key that references a column in another table

Correct Answer: Option A


Explanation:
A primary key is a column or set of columns that uniquely identifies each row in a table, ensuring entity integrity.

This question belongs to: Computer Database Management System (DBMS)