Difficulty: Easy
Correct Answer: Does not apply — subqueries are enclosed in parentheses ( ... )
Explanation:
Introduction / Context:
Subqueries are foundational in SQL. This question checks the correct syntax for enclosing them.
Given Data / Assumptions:
Concept / Approach:
A subquery is any SELECT embedded within another statement and must be enclosed in parentheses. Brackets may quote identifiers in some systems (e.g., [Order Details]) but are unrelated to subquery syntax.
Step-by-Step Solution:
Identify the construct: inner SELECT inside an outer statement.Recall standard syntax: (SELECT ...).Conclude that square brackets are incorrect for subquery delimiting.
Verification / Alternative check:
All major RDBMS documentation shows parentheses around subqueries.
Why Other Options Are Wrong:
Vendor support does not change this rule; correlation affects dependencies, not delimiters.
Common Pitfalls:
Confusing identifier quoting with subquery syntax; forgetting to alias subqueries in FROM.
Final Answer:
Does not apply — subqueries are enclosed in parentheses ( ... )
Discussion & Comments