oracle10未知字符集导入,未知导出(exp)用户的DMP文件导入(imp)方法及EXP-00091异常原因...

如果你手里有个exp导出的dmp文件,不知道导出用户,如何导入?

现在模拟一下,从test导出导入新建用户anbob

[oracle@orazhang ~]$ exp test/test file=test.dbf

Export: Release 10.2.0.1.0 - Production on 星期三 4月 13 17:19:24 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

Export done in ZHS16GBK character set and AL16UTF16 NCHAR character set

server uses AL32UTF8 character set (possible charset conversion)

. exporting pre-schema procedural objects and actions

. exporting foreign function library names for user TEST

. exporting PUBLIC type synonyms

. exporting private type synonyms

. exporting object type definitions for user TEST

About to export TEST's objects ...

. exporting database links

. exporting sequence numbers

. exporting cluster definitions

. about to export TEST's tables via Conventional Path ...

. . exporting table                       TESTCHAR          2 rows exported

EXP-00091: Exporting questionable statistics.

. . exporting table                       TESTNULL          1 rows exported

EXP-00091: Exporting questionable statistics.

. . exporting table                       TEST_PRO          2 rows exported

. . exporting table                      TEST_TRAN          5 rows exported

EXP-00091: Exporting questionable statistics.

. . exporting table                       TEST_TRI          1 rows exported

EXP-00091: Exporting questionable statistics.

. . exporting table                     TEST_UNUSE      50706 rows exported

EXP-00091: Exporting questionable statistics.

. exporting synonyms

. exporting views

. exporting stored procedures

. exporting operators

. exporting referential integrity constraints

. exporting triggers

. exporting indextypes

. exporting bitmap, functional and extensible indexes

. exporting posttables actions

. exporting materialized views

. exporting snapshot logs

. exporting job queues

. exporting refresh groups and children

. exporting dimensions

. exporting post-schema procedural objects and actions

. exporting statistics

Export terminated successfully with warnings.

[oracle@orazhang ~]$ ls

afiedt.buf   baiji.java  doub.java  ed.hup        orcldrop.sql  test.dbf

a.sql        b.sql       Download   on.lst        record        wxWidgets-2.9.1

baiji.class  Desktop     dwhelper   oraInventory  sqlnet.log

[oracle@orazhang ~]$ ora

SQL*Plus: Release 10.2.0.1.0 - Production on 星期三 4月 13 17:19:44 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

SQL> create user anbob identified by anbob;

User created.

SQL> grant connect,resource to anbob;

Grant succeeded.

SQL> exit

Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

[oracle@orazhang ~]$ imp anbob/anbob file=test.dbf;

Import: Release 10.2.0.1.0 - Production on 星期三 4月 13 17:20:46 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

Export file created by EXPORT:V10.02.01 via conventional path

Warning: the objects were exported by TEST, not by you

import done in ZHS16GBK character set and AL16UTF16 NCHAR character set

import server uses AL32UTF8 character set (possible charset conversion)

.importing TEST's objects into ANBOB

Import terminated successfully without warnings.

[oracle@orazhang ~]$ imp anbob/anbob file=test.dbf full=y;

Import: Release 10.2.0.1.0 - Production on 星期三 4月 13 17:24:32 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

Export file created by EXPORT:V10.02.01 via conventional path

Warning: the objects were exported by TEST, not by you

import done in ZHS16GBK character set and AL16UTF16 NCHAR character set

import server uses AL32UTF8 character set (possible charset conversion)

. importing TEST's objects into ANBOB

. . importing table                     "TESTCHAR"          2 rows imported

. . importing table                     "TESTNULL"          1 rows imported

. . importing table                     "TEST_PRO"          2 rows imported

. . importing table                    "TEST_TRAN"          5 rows imported

. . importing table                     "TEST_TRI"          1 rows imported

. . importing table                   "TEST_UNUSE"      50706 rows imported

Import terminated successfully without warnings.

[oracle@orazhang ~]$ ora

SQL*Plus: Release 10.2.0.1.0 - Production on 星期三 4月 13 17:24:59 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

SQL> conn anbob/anbob

Connected.

SQL> select count(*) from tab;

COUNT(*)

----------

6

------------------------------------------------

导出成功,数据也没问题,但大伙应该注意到导出的时候有异常EXP-00091: Exporting questionable statistics

是因为数据库的字符集和客户端(NLS_LANG)的字符集不一致导致的,修改一致后,再试一下

数据库字符集:

SQL> RUN

1  select * from database_properties where property_name like '%SET%'

2*

rows will be truncated

PROPERTY_NAME                                                PROPERTY_VALUE

------------------------------------------------------------ -----------------------------------------------------------------------------------------

NLS_CHARACTERSET AL32UTF8

NLS_NCHAR_CHARACTERSET                                       AL16UTF16

NLS_LANG字符集

[oracle@orazhang ~]$ echo $NLS_LANG

Simplified Chinese_china.ZHS16GBK

[oracle@orazhang ~]$ export NLS_LANG="Simplified Chinese_china.AL32UTF8"

[oracle@orazhang ~]$ exp test/test file=c.dbf

Export: Release 10.2.0.1.0 - Production on 鏄熸湡涓?4鏈?13 17:45:25 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

Export done in AL32UTF8 character set and AL16UTF16 NCHAR character set

. exporting pre-schema procedural objects and actions

. exporting foreign function library names for user TEST

. exporting PUBLIC type synonyms

. exporting private type synonyms

. exporting object type definitions for user TEST

About to export TEST's objects ...

. exporting database links

. exporting sequence numbers

. exporting cluster definitions

. about to export TEST's tables via Conventional Path ...

. . exporting table                       TESTCHAR          2 rows exported

. . exporting table                       TESTNULL          1 rows exported

. . exporting table                       TEST_PRO          2 rows exported

. . exporting table                      TEST_TRAN          5 rows exported

. . exporting table                       TEST_TRI          1 rows exported

. . exporting table                     TEST_UNUSE      50706 rows exported

. exporting synonyms

. exporting views

. exporting stored procedures

. exporting operators

. exporting referential integrity constraints

. exporting triggers

. exporting indextypes

. exporting bitmap, functional and extensible indexes

. exporting posttables actions

. exporting materialized views

. exporting snapshot logs

. exporting job queues

. exporting refresh groups and children

. exporting dimensions

. exporting post-schema procedural objects and actions

. exporting statistics

Export terminated successfully without warnings.

「喜欢文章,快来给作者赞赏墨值吧」 赞赏

【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论

请登录后发表评论

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值