修改oracle编码格式

文章参照:https://www.jb51.net/article/53078.htm

1.查看oracle当前编码格式:

  1. SELECT * FROM V$NLS_PARAMETERS WHERE PARAMETER = 'NLS_CHARACTERSET' ;
  2. SELECT USERENV('language') FROM DUAL;

   NLS_CHARACTERSET    AL32UTF8   

   SIMPLIFIED CHINESE_CHINA.AL32UTF8 

2.以sysdba身份登录

3.关闭数据库 shutdown immediate;

4.以mount打来数据库,startup mount

5.设置session

  1. SQL>ALTER SYSTEM ENABLE RESTRICTED SESSION;
  2. SQL> ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
  3. SQL> ALTER SYSTEM SET AQ_TM_PROCESSES=0;

6.启动数据库

alter database open;

7.修改字符集

ALTER DATABASE CHARACTER SET ZHS16GBK;

提示我们的字符集:新字符集必须为旧字符集的超集:

ALTER DATABASE character set INTERNAL_USE ZHS16GBK;

8.关闭,重新启动

shutdown immediate;

startup

原文地址;https://blog.csdn.net/u011229848/article/details/82384022

posted @ 2019-07-10 16:42  星朝  阅读(3986)  评论(0编辑  收藏  举报