QUESTION NO: 1
Evaluate the SQL statement:
TRUNCATE TABLE DEPT;
Which three are true about the SQL statement? (Choose three.)
A. It releases the storage space used by the table.
B. It does not release the storage space used by the table.
C. You can roll back the deletion of rows after the statement executes.
D. You can NOT roll back the deletion of rows after the statement executes.
E. An attempt to use DESCRIBE on the DEPT table after the TRUNCATE statement executes will display an error.
F. You must be the owner of the table or have DELETE ANY TABLE system privileges to truncate the DEPT table
Answer: A,D,F
答案解析:
参考:http://docs.oracle.com/cd/E11882_01/server.112/e25494/general.htm#ADMIN11534
It is a DDL statement and cannot be rolled back D正确,C错误
A TRUNCATE
statement also specifies whether space currently allocated for the table is returned to the containing tablespace after truncation. A正确。B错误
You can truncate any table or cluster in your own schema. Any user who has the DROP ANY TABLE
system privilege can truncate a table or cluster in any schema. F正确。
sys@TESTDB>conn scott/tiger
Connected.
scott@TESTDB>select * from dept_new