Which expression can be used to create a temporary name for a table?
A.
HAVING
B.
NEW
C.
ALIAS
D.
UNION
The Answer Is:
C
This question includes an explanation.
Explanation:
Analiasis used in SQL to give atemporaryname to a table or column within a query. It makes queries more readable and helps in cases where a table needs to be referenced multiple times (e.g., in aself-join).
Example Usage:
sql
SELECT e.Name, d.DepartmentName
FROM Employees AS e
JOIN Departments AS d
ON e.DeptID = d.ID;
Here,Employees is aliased as eandDepartments as d, making the query shorter and clearer.
Why Other Options Are Incorrect:
Option A (HAVING) (Incorrect):Used to filter grouped results, not create aliases.
Option B (NEW) (Incorrect):Not a valid SQL keyword for aliasing.
Option D (UNION) (Incorrect):Combines result sets but does not rename tables.
Thus, the correct answer isALIAS, which allows fortemporary naming of tables or columns.
[Reference:SQL Aliases and Temporary Naming., ]
Data-Management-Foundations PDF/Engine
Printable Format
Value of Money
100% Pass Assurance
Verified Answers
Researched by Industry Experts
Based on Real Exams Scenarios
100% Real Questions
Get 75% Discount on All Products,
Use Coupon: "ac75sure"