重庆分公司,新征程启航
为企业提供网站建设、域名注册、服务器等服务
1.(Window:)cmd下输入set ORACLE_SID=你想进入的数据库的那个sid
创新互联建站专注于凤庆网站建设服务及定制,我们拥有丰富的企业做网站经验。 热诚为您提供凤庆营销型网站建设,凤庆网站制作、凤庆网页设计、凤庆网站官网定制、重庆小程序开发服务,打造凤庆网络公司原创品牌,更为您提供凤庆网站排名全网营销落地服务。
(Linux:)切换到oracle用户:export ORACLE_SID=你想进入的数据库的那个sid
2.输入 sqlplus /nolog
3.将数据库启动到RESTRICTED模式下做字符集更改:
SQL> conn /as sysdba
Connected.
SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area 236000356 bytes
Fixed Size 451684 bytes
Variable Size 201326592 bytes
Database Buffers 33554432 bytes
Redo Buffers 667648 bytes
Database mounted.
SQL> ALTER SYSTEM ENABLE RESTRICTED SESSION;
System altered.
SQL> ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
System altered.
SQL> ALTER SYSTEM SET AQ_TM_PROCESSES=0;
System altered.
SQL> alter database open;
Database altered.
--修改为中文字符集
SQL> ALTER DATABASE character set INTERNAL_USE ZHS16GBK;
--修改为英文字符集
SQL> ALTER DATABASE character set INTERNAL_USE AL32UTF8;
Database altered.
SQL> select * from v$nls_parameters;
略
19 rows selected.
重启检查是否更改完成:
SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 236000356 bytes
Fixed Size 451684 bytes
Variable Size 201326592 bytes
Database Buffers 33554432 bytes
Redo Buffers 667648 bytes
Database mounted.
Database opened.
SQL> select * from v$nls_parameters;