impdp ORA-39083: Object type INDEX_STATISTICS failed to create with error

来源:互联网 发布:apache 长度 编辑:程序博客网 时间:2024/06/04 17:40

ORA-39083: Object type INDEX_STATISTICS failed to create with error:
ORA-01403: no data found
ORA-01403: no data found
Failing sql is:

 

 

导入的时候添加EXCLUDE=STATISTICS选项就ok了,导入结束之后使用dbms_stats.gather_schema_stats重新搜集统计信息。

 

 

导入命令示例:

 

impdp system/test dumpfile=expdat.dmp directory=tran exclude=transportable_export/materialized_view,transportable_export/table_statistics,transportable_export/grant/owner_grant/object_grant transport_datafiles='/oradata/oradata/testzj/ndmain1.dbf','/oradata/oradata/testzj/ndmain2.dbf'

 

 

在导入时有三个部分对象排除出去:
transportable_export/materialized_view:因为是测试环境,不需要同步数据,所以没有必要创建物化视图
transportable_export/grant/owner_grant/object_grant:因为新环境有很多用户不存在,保留授权会导致一大堆的报错信息,故排除
transportable_export/table_statistics:不导入表统计信息是为了避免bug:
ORA-39083: Object type TABLE_STATISTICS failed to create with error:
ORA-06550: line 12, column 17:
PL/SQL: ORA-00917: missing comma
ORA-06550: line 4, column 127:
PL/SQL: SQL Statement ignored

 

 

refer:http://space6212.itpub.net/post/12157/411375

原创粉丝点击