/////////////客户端、服务端字符集的查看后面补上
1 修改服务器的字符集,直接修改prop$表,将NLS_CHAR字符集改为ZHS16GBK
UPDATE PROPS$ SET VALUE$='ZHS16GBK' WHERE NAME='NLS_CHARACTERSET';
2 修改客户端字符集 regedit/nls_lang = AMERICAN_AMERICA.ZHS16GBK (具体路径google)
3 oracle字符集修改的地方很多,只是修改了上面的地方,会报各种奇怪的错,继续下面的修改
则进行如下处理:
SHUTDOWN IMMEDIATE;
STARTUP MOUNT;
ALTER SYSTEM ENABLE RESTRICTED SESSION;
ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
ALTER SYSTEM SET AQ_TM_PROCESSES=0;
ALTER DATABASE OPEN;
COL VALUE NEW_VALUE CHARSET
SELECT VALUE FROM NLS_DATABASE_PARAMETERS WHERE PARAMETER='NLS_CHARACTERSET';
COL VALUE NEW_VALUE NCHARSET
SELECT VALUE FROM NLS_DATABASE_PARAMETERS WHERE PARAMETER='NLS_NCHAR_CHARACTERSET';
--INTERNAL_USE是没有写在文档中的参数,用以强制完成字符集一致化
ALTER DATABASE CHARACTER SET INTERNAL_USE &CHARSET;
ALTER DATABASE NATIONAL CHARACTER SET INTERNAL_USE &NCHARSET;
SHUTDOWN IMMEDIATE;
STARTUP;