Evaluate the following SQL statement: SQL> selec…

Evaluate the following SQL statement:
SQL> select cust_id, cust_last_name “Last name”
FROM customers
WHERE country_id = 10
UNION
SELECT cust_id CUST_NO, cust_last_name
FROM customers
WHERE country_id = 30
Identify three ORDER BY clauses either one of which can complete the query.

Evaluate the following SQL statement:
SQL> select cust_id, cust_last_name “Last name”
FROM customers
WHERE country_id = 10
UNION
SELECT cust_id CUST_NO, cust_last_name
FROM customers
WHERE country_id = 30
Identify three ORDER BY clauses either one of which can complete the query.

A.
ORDER BY “Last name”

B.
ORDER BY 2, cust_id

C.
ORDER BY CUST_NO

D.
ORDER BY 2, 1

E.
ORDER BY “CUST_NO”



Leave a Reply 1

Your email address will not be published. Required fields are marked *


evilsoldier

evilsoldier

Only colum names, aliases or positions that are part of the first SELECT can be used for sorting.