您的位置:首页 > 数据库 > Oracle

Oracle迁移索引

2012-08-28 13:56 148 查看
第一条,clob的索引别乱动

ALTER TABLE table_a MOVE TABLESPACE Tbs_tb

LOB (ATTRIBUTE) STORE AS(TABLESPACE tbs_lob);

快速指南:

alter index schema.index_1 rebuild tablespace TBS_IDX;

批量的话可以写个sql,例如:

select 'alter index '||a.owner||'.'||a.index_name||' rebuild tablespace TBS_IDX;',

a.owner,a.index_name,a.tablespace_name from dba_indexes a

where a.Owner='USER_A'

order by a.owner,a.table_name;

本文出自 “机动战士高达Oracle” 博客,请务必保留此出处http://gundam.blog.51cto.com/1845787/975265
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: