将索引移动到别的表空间
2015-01-18 20:40
162 查看
alter index index_name rebuild tablespace tablespace_name online nologging parallel;
SQL> select segment_name,segment_type,tablespace_name from user_segments where segment_name='EMP_DEPTNO';
SEGMENT_NAME SEGMENT_TYPE TABLESPACE_NAME
--------------------------------------------------------------------------------- ------------------ ----------------------------
EMP_DEPTNO INDEX MY_INDEX
SQL> alter index emp_deptno rebuild online tablespace users nologging parallel 4 ;
索引已更改。
SQL> select segment_name,segment_type,tablespace_name from user_segments where segment_name='EMP_DEPTNO';
SEGMENT_NAME SEGMENT_TYPE TABLESPACE_NAME
--------------------------------------------------------------------------------- ------------------ -------------------
EMP_DEPTNO INDEX USERS
online表示重建索引时不对原表的dml操作产生影响,
nologging只是为了加速索引的创建速度,
parallel也是为了加快索引创建速度,不过使用parallel时要小心,不能在资源不足的情况下使用,否者产生direct path read /write等待事件。
SQL> select segment_name,segment_type,tablespace_name from user_segments where segment_name='EMP_DEPTNO';
SEGMENT_NAME SEGMENT_TYPE TABLESPACE_NAME
--------------------------------------------------------------------------------- ------------------ ----------------------------
EMP_DEPTNO INDEX MY_INDEX
SQL> alter index emp_deptno rebuild online tablespace users nologging parallel 4 ;
索引已更改。
SQL> select segment_name,segment_type,tablespace_name from user_segments where segment_name='EMP_DEPTNO';
SEGMENT_NAME SEGMENT_TYPE TABLESPACE_NAME
--------------------------------------------------------------------------------- ------------------ -------------------
EMP_DEPTNO INDEX USERS
online表示重建索引时不对原表的dml操作产生影响,
nologging只是为了加速索引的创建速度,
parallel也是为了加快索引创建速度,不过使用parallel时要小心,不能在资源不足的情况下使用,否者产生direct path read /write等待事件。
相关文章推荐
- 把表和索引移动到另外的表空间
- 如何移动LOB索引到其他表空间
- 如何把索引移动到另外的表空间
- 移动表到新表空间后重建索引
- 移动分区表和分区索引的表空间
- 【转】移动oracle LOB索引到其他表空间
- 将索引移动到别的表空间
- 移动分区表和分区索引的表空间
- 移动 表、表分区、LOB字段、索引、分区索引 到另一表空间!
- 移动lob类型索引到指定表空间
- 将索引移动到别的表空间
- Oracle表和索引移动表空间
- 移动分区表和分区索引的表空间
- IFS ERP索引空间不能扩展的临时解决方案
- 当LINUX某个目录下文件占有空间很大时,除了用移动到其它大存储上的方法,还可用软链
- 在ORACLE数据库间移动或复制表空间测试
- oracle spatial 创建空间字段索引 创建字段索引 完善SQL语句实例
- 解决ORA-29857:表空间中存在域索引和/或次级对象 & ORA-01940:无法删除当前连接的用户问题 分类: oracle sde 2015-07-30 20:13 8人阅读 评论(0) 收藏
- SqlServer中查看数据库所有表的表空间和索引空间信息
- information_schema系列六(索引,表空间,权限,约束相关表)