【OCP题库】最新CUUG OCP 12c 071考试题库(65题)
65、(22-16) choose the best answer:
The CUSTOMERS table has the following structure:
You need to write a query that does the following tasks:
1. Display the first name and tax amount of the customers. Tax is 5% of their credit limit.
2. Only those customers whose income level has a value should be considered.
3. Customers whose tax amount is null should not be considered.
Which statement accomplishes all the required tasks?
A) SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT
FROM customers
WHERE (cust_income_level,tax_amount) IS NOT NULL;
B) SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT
FROM customers
WHERE cust_income_level IS NOT NULL AND
cust_credit_limit IS NOT NULL;
C) SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT
FROM customers
WHERE cust_income_level <> NULL AND
tax_amount <> NULL;
D) SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT
FROM customers
WHERE cust_income_level IS NOT NULL AND
tax_amount IS NOT NULL;
Answer:B
(解析:条件语句中不能用别名当做条件,该题的题意是税额不能为 0,所以只要 cust_credit_limit 不为 0,则保证税额不会为 0
【OCP题库】最新CUUG OCP 12c 071考试题库(65题)的更多相关文章
- 【OCP题库】最新CUUG OCP 12c 071考试题库(68题)
68.(29-13)choose two: Which two statements are true? (Choose two.) A) DICTIONARY is a view that cont ...
- 【OCP题库】最新CUUG OCP 12c 071考试题库(67题)
67.(25-8)choose the best answer: View the Exhibit and examine the structure of CUSTOMERS table. Eval ...
- 【OCP题库】最新CUUG OCP 12c 071考试题库(66题)
66.(22-19)choose two Examine the structure proposed for the TRANSACTIONS table: Which two statements ...
- 【OCP题库-12c】最新CUUG OCP 071考试题库(72题)
72.View the exhibit for the structure of the STUDENTand FACULTYtables. STUDENT Name Null? Type ----- ...
- 【OCP题库-12c】最新CUUG OCP 071考试题库(71题)
71.(32-18) choose three Which three statements indicate the end of a transaction? (Choose three.) A) ...
- 【OCP题库-12c】最新CUUG OCP 071考试题库(70题)
70.(31-2)choose the best answer: View the Exhibit and examine the structure of the Book table. The B ...
- 【OCP题库-12c】最新CUUG OCP 071考试题库(69题)
69.(31-1)choose the best answer: Evaluate the following query: SELECT INTERVAL '300' MONTH, INTERVAL ...
- 【OCP-12c】2019年CUUG OCP 071考试题库(74题)
74.View the exhibit and examine the structure of ORDERS and CUSTOMERS tables. ORDERS Name Null? ...
- 【OCP-12c】2019年CUUG OCP 071考试题库(80题)
80.View the exhibit and examine the structure in ORDERS and ORDER_ITEMS tables. You need to create a ...
随机推荐
- ManagedProperty not injected in @FacesConverter
I'm trying to inject a ManagedBean in my FacesConverted the following way: @ManagedBean @RequestScop ...
- C#流对象使用完后不立即释放的问题
public class testwriter : MonoBehaviour { // Use this for initialization void Start () { } [MenuItem ...
- rook
https://github.com/rook/rook https://rook.github.io/docs/rook/master/ Rook是在云本地环境中运行的分布式存储系统的开源编排器. ...
- shell中的字符串操作和数学运算
字符串操作 变量赋值: 说明:变量值可以用单引号.双引号.或者不加任何引号来赋值给变量 变量名="变量值" 变量名='变量值' 变量名=变量值 例如:str="hel ...
- Python_06-函数与模块
1.获取当前路径 >>> import os >>> os.path() >>> os.getcwd() 'D:\\Python34' os.pa ...
- iOS下nil 、NULL、 Nil 、NSNull的区别
1.nil,定义一个空的实例,指向OC中对象的空指针. 示例代码: NSString *someString = nil; NSURL *someURL = nil; id someObject = ...
- basicHttpBinding
表示一个绑定,Windows Communication Foundation (WCF) 服务可以使用此绑定配置和公开能够与基于 ASMX 的 Web 服务和客户端通信的终结点以及符合 WS-I B ...
- 除了DFS的空间恒定为宽度*深度之外,其余都是宽度^深度次方
- golang之递归
翠花,上代码 package main import ( "fmt" "time" ) /* 递归原则,一个大问题分解成相似的小问题 定义好出口条件,否则死循环 ...
- C/C++互相调用
参考: http://www.cnblogs.com/Yogurshine/p/3913073.html http://blog.chinaunix.net/uid-24118190-id-29853 ...