SELECT Queries - 1

📝 SELECT Queries - 1

Total Questions: 5
Click an answer to select it, then click "Check Answers" to see your results.
Question 1

Which clause is used to specify the table from which data is retrieved in a SQL query?

A.

A) SELECT

B.

B) FROM

C.

C) WHERE

D.

D) ORDER BY

Question 2

Why must the FROM clause always execute before the WHERE clause in SQL?

A.

A) Because WHERE needs access to the table data that FROM retrieves

B.

B) Because the database optimizer requires it

C.

C) Because SELECT cannot work without FROM first

D.

D) Because it improves query performance

Question 3

If a query has both WHERE and HAVING filtering different conditions, in what order do they execute?

A.

A) HAVING first, then WHERE

B.

B) WHERE first, then HAVING

C.

C) Simultaneously

D.

D) The order depends on the database system

Question 4

A database administrator asks you to retrieve all project information from the Projects table to verify the data exists. Which query should you use?

A.

A) SELECT * FROM Projects;

B.

B) SELECT ProjectName FROM Projects;

C.

C) SELECT ProjectID FROM Projects;

D.

D) SHOW * FROM Projects;

Question 5

What is the purpose of replacing * with specific column names in a SELECT statement?

A.

A) To sort the results alphabetically

B.

B) To limit output to only desired fields from the table

C.

C) To create a new table

D.

D) To filter rows based on conditions

Quiz Complete!

Score: 0 / 5