Oracle19c OCP(1Z0-082 Q1)题库解析 oracle ocp题库 云贝教育郭一军(微信:guoyJoe)原创

考试科目:1Z0-082
考试题量:90
通过分数:60%
考试时间:150min
[本文为云贝教育郭一军(微信:guoyJoe)原创,请尊重知识产权,转发请注明出处,不接受任何抄袭、演绎和未经注明出处的转载。]https://www.yunbee.net/Home/News/detail/article_id/234.html

1. Which two statements are true about space-saving features in an Oracle Database?
A.An index created with the UNUSABLE attribute has no segment.
B.Private Temporary Tables(PTTs)store metadata in memory only.
C.Private Temporary Tables(PTTs) when used, are always dropped at the next commit statement.
D.An index that is altered to be UNUSABLE will retain its segment.
E. A table that is truncated will always have all of its extents removed.

参考答案:AB

解析:
A:不可用索引会自动删除segment,但是索引分区后,某个分区的索引不可用,其它索引段还在的
B:私有临时表这个特性18C才引入(https://docs.oracle.com/en/database/oracle/oracle-database/18/admin/managing-tables.html#GUID-9B373086-0760-4B18-9688-BACFF07EC74B)
C:私有临时表和全局临时表都有ON COMMIT DELETE ROWS和ON COMMIT PRESERVE ROWS的两种分类(delete rows用于事务相关,也就在事务结束后truncate data in the temporary table,preserve rows表示在会话结束后清除临时表的数据)
D:不可用的索引会被删除段,已使用alter index unusable测试
E:普通表截断后会保留min_extents设置的初始区段大小

sys@PROD> conn yunbee/yunbee@pdb1

Connected.

yunbee@PDB1> create table t10(id int,name varchar(100));



Table created.

yunbee@PDB1> begin

2  for i in 1 .. 50000 loop

3    insert into t10 values(i,'aaaaa');

4    commit;

5    end loop;

6  end;

7  /



PL/SQL procedure successfully completed.

yunbee@PDB1> select extent_id,file_id,block_id from dba_extents where segment_name='T10';

EXTENT_ID    FILE_ID  BLOCK_ID

---------- ---------- ----------

0        12        160

1        12        168

2        12        176

3        12        184

4        12        192

5        12        200

6        12        208

7        12        216

8        12        224

9        12        232

10        12        240

11        12        248

12        12        256

13        12        264

14        12        272



yunbee@PDB1> truncate table t10;

Table truncated.

yunbee@PDB1> select extent_id,file_id,block_id from dba_extents where segment_name='T10';



EXTENT_ID    FILE_ID  BLOCK_ID

---------- ---------- ----------

0        12        160
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 2
    评论
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值