EXP,IMP遷移資料庫的時候注釋亂碼解決方案

來源:互聯網
上載者:User



原因是匯出的時候用戶端字元集沒有設定,或者設定不對。修改成DB的就OK了


查了一下字元集(select userenv('language') from dual;)


匯出庫的字元集是 SIMPLIFIED CHINESE_CHINA.ZHS16GBK  


匯入庫的字元集是  AMERICAN_AMERICA.ZHS16GBK


匯入用戶端的字元集是 AMERICAN_AMERICA.ZHS16GBK
-----------------------


後匯出端的NLS_LANG,發現沒有這個變數,我是用oracle使用者匯出的.所以沒有設定.沒有 NLS_LANG


修改.bash_profile 加上 NLS_LANG=AMERICAN_AMERICA.ZHS16GBK


source .bash_profile


重新匯出.


再修改匯入的用戶端為NLS_LANG=AMERICAN_AMERICA.ZHS16GBK


匯入的資料表的注釋正常

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.