OCP-1Z0-新051-61题版本-27

QUESTION NO: 27

Which statement is true regarding the UNION operator?

A. The number of columns selected in all SELECT statements need to be the same

B. Names of all columns must be identical across all SELECT statements

C. By default, the output is not sorted

D. NULL values are not ignored during duplicate checking

Answer: D

答案解析:

参考:152:http://blog.csdn.net/rlhua/article/details/12884213

Explanation:

The columns in the queries that make up a compound query can have different names, but the

output result set will use the names of the columns in the first query.

A compound query will by default return rows sorted across all the columns, from left to right. The

only exception is UNION ALL, where the rows will not be sorted. The only place where an ORDER

BY clause is permitted is at the end of the compound query.

Oracle Server and Set Operators

• Duplicate rows are automatically eliminated except in UNION ALL.

• Column names from the first query appear in the result.

• The output is sorted in ascending order by default except in UNION ALL.

原文地址:https://www.cnblogs.com/hzcya1995/p/13316220.html