ITPub博客

首页 > 数据库 > Oracle > OCP 1Z0-051-69

OCP 1Z0-051-69

原创 Oracle 作者:LuiseDalian 时间:2014-05-15 07:22:36 0 删除 编辑
(69)You need to generate a list of all customer last names with their credit limits from the CUSTOMERS table.

Those customers who do not have a credit limit should appear last in the list.

Which two queries would achieve the required result? (Choose two.)

A.

SELECT cust_last_name, cust_credit_limit

FROM customers ORDER BY cust_credit_limit DESC ;

B.

SELECT cust_last_name, cust_credit_limit

FROM customers ORDER BY cust_credit_limit;

C.

SELECT cust_last_name, cust_credit_limit

FROM customers ORDER BY cust_credit_limit NULLS LAST;

D.

SELECT cust_last_name, cust_credit_limit

FROM customers ORDER BY cust_last_name, cust_credit_limit NULLS LAST;

答案:(B、C)

解析:

升序时NULL值显示在最后,DESC时NULL显示在最前面

可以指定NULLS FIRST或NULLS LAST来决定NULL值放在最前面还是最后面



来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/17013648/viewspace-1161527/ ,如需转载,请注明出处,否则将追究法律责任。

上一篇: OCP 1Z0-051-51
下一篇: OCP 1Z0-051-64
请登录后发表评论 登录
全部评论

注册时间:2012-02-06

  • 博文量
    1986
  • 访问量
    6043848