OCP 1Z0 051 68

来源:互联网 发布:java set 取值 编辑:程序博客网 时间:2024/05/16 16:15
68. Which statement is true regarding the default behavior of the ORDER BY clause? 
A. In a character sort,   the values are case- sensitive. 
B. NULL values are not considered at all by the sort operation. 
C. Only those columns that are specified in the SELECT list can be used in the ORDER BY clause. 
D. Numeric values are displayed from the maximum to the minimum value if they have decimal positions. 

order by 区分大小写, 排序时NULL当作无限大
SQL> select id,c1 from t1 order by c1;    ID C1------ --     1 A     3 B     2 a     4 b     6      5 6 rows selectedSQL> select id,c1 from t1 order by c1 desc;    ID C1------ --     5      6      4 b     2 a     3 B     1 A6 rows selected

没在select里的列也可以参与order by 
SQL> select id from t1 order by c1 desc;    ID------     5     6     4     2     3     16 rows selectedSQL> select id from t1 order by c1;    ID------     1     3     2     4     6     56 rows selected

至于D,谁来告诉我,这是什么逻辑,难道是一个来凑数的选项?
SQL> select db from t1;                  DB--------------------              120.63              169.27              177.81              157.15              179.32              152.096 rows selected


Answer: A 
0 0
原创粉丝点击