What is a subquery in SQL? MCQ with Answer and Explanation

What is a subquery in SQL?
A. A query that returns multiple results
B. A query that is always correlated
C. A query nested inside another query
D. A query that is used to create a table
Answer: Option C
Solution (By JKSSB Mock Tests)
A subquery is a SELECT statement nested within another SQL statement (e.g., SELECT, INSERT, UPDATE, DELETE).

Discuss this Question (0)

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

Practice More Database Management System (DBMS) Questions

Question #1
Data that has been processed, organized, structured, or presented in a given context to make it useful is known as what?
A. Information
B. Field
C. Raw facts
D. Database

Correct Answer: Option A


Explanation:
Information is data that has been processed, structured, or organized in a meaningful way to provide context and utility to the user.

This question belongs to: Computer Database Management System (DBMS)
Question #2
Which of the following is a valid SQL data type for a date and time?
A. DATE
B. DATETIME
C. TIMESTAMP
D. All of the above

Correct Answer: Option D


Explanation:
Different DBMS support DATETIME, TIMESTAMP, DATE, etc. All are valid date/time types.

This question belongs to: Computer Database Management System (DBMS)
Question #3
In an Entity-Relationship (ER) diagram, attributes are represented using which shape?
A. Square
B. Ellipse/Oval
C. Rectangle
D. Diamond

Correct Answer: Option B


Explanation:
Ellipses or ovals are used to represent attributes (properties) of entities in ER diagrams.

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