[转帖]alert错误1—中ORA-20000问题的解决办法_MySQL, Oracle及数据库讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  MySQL, Oracle及数据库讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 3871 | 回复: 0   主题: [转帖]alert错误1—中ORA-20000问题的解决办法        下一篇 
derek
注册用户
等级:中校
经验:1550
发帖:209
精华:0
注册:2011-7-21
状态:离线
发送短消息息给derek 加好友    发送短消息息给derek 发消息
发表于: IP:您无权察看 2011-8-1 21:53:45 | [全部帖] [楼主帖] 楼主

ORA-20000: index "ZXDBM_890"."IDX_STAT_FACT_ORDER_USERID"  or partition of such index is in unusable state


XXX项目是XXX的决策系统,OLAP,传说中的数据仓库,运用了很多oracle高级技术:分区、并行执行等。

粗率分析应该是分区索引失效导致的,由于现网工程还无法联系上,还无法定位。网络上有类似的解决方案,如下

ALTER INDEX "BUSINESS"."IDX_IC_JSDB_PART"
REBUILD
PARTITION "P2010_2"
TABLESPACE "INDEX01"


导致如下错误

Fri Feb 19 22:04:03 2010
Errors in file /u01/oracle/admin/bxrac/bdump/bxrac4_j002_29756.trc:
ORA-20000: index "BUSINESS"."IDX_IC_JSDB_PART"  or partition of such index is in unusable state


检查index的状态

SQL> select status from dba_indexes where index_name='IDX_IC_JSDB_PART';
STATUS
------------------------
N/A


手工执行分析脚本;

SQL> exec dbms_stats.gather_table_stats('business','IC_JSDB');
BEGIN dbms_stats.gather_table_stats('business','IC_JSDB'); END;
*
ERROR at line 1:
ORA-20000: index "BUSINESS"."IDX_IC_JSDB_PART"  or partition of such index is
in unusable state
ORA-06512: at "SYS.DBMS_STATS", line 13437
ORA-06512: at "SYS.DBMS_STATS", line 13457
ORA-06512: at line 1


解决办法:
重新建立

SQL> alter index IDX_IC_JSDB_PART rebuild online;
Index altered.


测试分析脚本是否可用

SQL> exec dbms_stats.gather_table_stats('business','IC_JSDB');


处理问题参考:

--------------------------------------------------------------------------------------------------------------
ORA-20000 - index "SCOTT"."SSMTEST _U0" or partition of such index is in unusable state. During generating
gather statistics on table.
ORA-20000: index "SCOTT"."SSMTEST_U0"  or partition of such
index is in unusable state
ORA-06512: at "SYS.DBMS_STATS", line 13189
ORA-06512: at "SYS.DBMS_STATS", line 13209
ORA-06512: at line 1
The general for this error I came across is having duplicate rows in table.
Use following steps to reslove this error.
1) Find out dpulicate rows from table.
2) drop index
3) delete duplicate rows from table.
4) Re-Create Index.
5) Generate statistic on table.




赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论