ORA-38029: 对象统计信息已锁定
随即查了一下——
-bash-3.00$ oerr ora 38029
38029, 00000, "object statistics are locked"
// *Cause: An attept was made to modify optimizer statistics of the object.
// *Action: Unlock statistics with the DBMS_STATS.UNLOCK_TABLE_STATS procedure
// on base table(s). Retry the operation if it is okay to update statistics.
于是就找UNLOCK_TABLE_STATS 的用法,在DBMS_STATS包中查找,也发现有UNLOCK_SCHEMA_STATS procedure,于是就干脆执行——
SQL> begin
2 DBMS_STATS.UNLOCK_schema_STATS(user);
3 end;
4 /PL/SQL 过程已成功完成。
exec dbms_stats.unlock_table_stats('CSHOW','cmpp_send_mass');
analyze table cmpp_send_mass compute statistics for table for all indexes for all indexed columns;