签到成功

知道了

CNDBA社区CNDBA社区

记一次oracle imp导入时遇到字符集告警后修改字符集的过程

2016-09-02 13:14 5188 1 原创
作者: shmily

有个朋友说只有exp出来的备份,需要进行恢复,然后远程帮朋友恢复的时候遇到点字符集的问题,记录下

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
server uses AL32UTF8 character set (possible charset conversion)

About to export speciied tables via Conventional Path ...

执行恢复的时候报出上面的警告,然后倒入过程中只倒入了部分数据,有大量的报错

http://www.cndba.cn/asker/article/147

IMP-00019,IMP-00003,ORA-12899值过大,数据倒入表失败,分析过后,因为字符集的问题,数据插入到库中大小变了。http://www.cndba.cn/asker/article/147


修改数据库字符集过程:

http://www.cndba.cn/asker/article/147

shutdown immediate

startup restrict

alter database character set AL32UTF8;

http://www.cndba.cn/asker/article/147
http://www.cndba.cn/asker/article/147

ORA-12712: new character set must be a superset of old character set
RROR at line 1:

结果报错,提示新字符集必须是老字符集的超集。http://www.cndba.cn/asker/article/147

http://www.cndba.cn/asker/article/147

于是强制转换

ALTER DATABASE character set INTERNAL_USE AL32UTF8;

http://www.cndba.cn/asker/article/147
http://www.cndba.cn/asker/article/147

alter system diable restricted session;http://www.cndba.cn/asker/article/147

字符集修改到这完成


版权声明:本文为博主原创文章,未经博主允许不得转载。

用户评论
* 以下用户言论只代表其个人观点,不代表CNDBA社区的观点或立场
shmily

shmily

关注
  • 22
    原创
  • 0
    翻译
  • 2
    转载
  • 11
    评论
  • 访问:142168次
  • 积分:141
  • 等级:初级会员
  • 排名:第23名
精华文章
    热门文章
      Copyright © 2016 All Rights Reserved. Powered by CNDBA · 皖ICP备2022006297号-1·

      AI QQ群