OCP 1Z0 051 21

来源:互联网 发布:开放式厨房 知乎 编辑:程序博客网 时间:2024/05/21 21:42
21. Examine the description of the EMP_DETAILS table given below: 
name               NULL                 TYPE 
EMP_ID             NOT NULL             NUMBER 
EMP_NAME           NOT NULL             VARCHAR2 (40) 
EMP_IMAGE                              LONG 
Which  two  statements  are  true  regarding SQL statements  that  can  be  executed  on  the EMP_DETAIL 
table? (Choose two.) 
A. An EMP_IMAGE column can be included in the GROUP BY clause. 
B. An EMP_IMAGE column cannot be included in the ORDER BY clause. 
C. You cannot add a   new column to the table with LONG as the   data type. 
D. You can alter the table to include the   NOT NULL constraint on the EMP_IMAGE column. 

为什么老是考long.这是个不建议使用的类型

SQL> CREATE TABLE emp_details  2  (  3  emp_id NUMBER NOT NULL,  4  emp_name VARCHAR2(40) NOT NULL,  5  emp_image LONG  6  );Table createdSELECT emp_image FROM emp_details GROUP BY emp_imageORA-00997: 非法使用 LONG 数据类型SELECT emp_image FROM emp_details ORDER BY emp_imageORA-00997: 非法使用 LONG 数据类型ALTER TABLE emp_details ADD new_col LONGORA-01754: 表只能包含一个 LONG 类型的列SQL> ALTER TABLE emp_details MODIFY emp_image NOT NULL;Table altered


Answer: BC 
0 0
原创粉丝点击