现在的位置: 首页 > 综合 > 正文

如何在大表上建索引

2018年04月07日 ⁄ 综合 ⁄ 共 274字 ⁄ 字号 评论关闭

 1 alter session set work_policy = manual
2 alter session set sort_area_size=1024M
3 paralell 2 or 4
4 nologging
5 compute statistics
6 check your TEMP tablespace

sql>create unique index index_name on tablename(column) online nologging parallel 2 compute statistics;

做完后要记得将并行取消

SQL>alter index index_name noparallel;

抱歉!评论已关闭.