Direct import with script, Oracle garbled
The vast majority of cases are caused by inconsistent values of the Oracle Client environment variable Nls_lang and the database character set .
(Note Nls_lang modifies the encoding of the Oracle client character set, and Lang in the locale command is the system's character set (SuSE modified in/etc/sysconfig/language) (Redhat in/etc/sysprofile/ i18n))
View environment variables Echo $NLS _lang
View database Character Set select Userenv (' language ') from dual;
If the two are inconsistent, it is recommended to modify the Nls_lang, convenient, simple, safe
There are two ways to modify Nls_lnag
1, temporary modification in the current login terminal execution Export Nls_lang=xx (XX: Represents the database character set)
Fail after local login exits
Open two terminals and not shared
2, modify ~/.BASHRC permanently, add export nls_lang=en to the file. US. UTF-8 (XX: Indicates the database character set)
Permanent entry after re-login
If "Xx:not a valid identifier" appears when setting the environment variable, check if there are any spaces in XX, and if there are spaces, enclose the XX in double quotation marks. For example: Export nls_lang= "simplified Chinese_china. ZHS16GBK "
Oracle Import Script File garbled problem