Difficulty: Easy
Correct Answer: A view
Explanation:
Introduction / Context:Views are a core abstraction in SQL that present data from base tables through a stored query, often to simplify access or enforce security.
Given Data / Assumptions:
Concept / Approach:A view is defined with CREATE VIEW ... AS SELECT ... and behaves like a table in queries, though it does not store its own data (except materialized variants). It is distinct from ad hoc query results, which are transient.
Step-by-Step Solution:
Identify keywords “virtual table” and “constructed from other tables.”Associate with the SQL object “view.”Select “A view.”Verification / Alternative check:Attempt SELECT * FROM view_name after creation; this works like selecting from a table.
Why Other Options Are Wrong:
Common Pitfalls:Assuming views permanently store data; unless materialized, they compute results at query time.
Final Answer:A view
Discussion & Comments