Preface
 
    Today,I'm gonna say something what is related with the character set in Oracle database,the scenarios in changing character set from UTF8 to ZHS16GBK and the contra way as well.
    It' not recommended to modify character set in Oracle database because of the risk of lost data especially in changing superset to subset.Even though you can use "internal_use" option to change.
    You need to pay more attention in understanding some limitation in doing that.Data must be export with correct character set before you to really change it.Let's see the details below.
 
Environment
 
Hostname IP Linux Version Oracle Database SID
ogg 192.168.1.20 RHEL 5.7 11.2.0.1 ogg
 
Procedure
 
1. Set database character set from ZHS16GBK to UTF8.
 
Check the character set of database.
 SQL> set line  pages
SQL> col value for a40
SQL> select * from nls_database_parameters; PARAMETER VALUE
------------------------------ ----------------------------------------
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CHARACTERSET ZHS16GBK
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY $
NLS_COMP BINARY
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CONV_EXCP FALSE
NLS_NCHAR_CHARACTERSET AL16UTF16
NLS_RDBMS_VERSION 11.2.0.1. rows selected. SQL> select userenv('language') from dual; USERENV('LANGUAGE')
----------------------------------------------------
AMERICAN_AMERICA.ZHS16GBK
Create test user and test table.
 SQL> col file_name for a60
SQL> col tablespace_name for a30
SQL> select file_name,tablespace_name,bytes// from dba_data_files; FILE_NAME TABLESPACE_NAME BYTES//
------------------------------------------------------------ ------------------------------ ---------------
/u01/app/oracle/oradata/ogg/system01.dbf SYSTEM
/u01/app/oracle/oradata/ogg/sysaux01.dbf SYSAUX
/u01/app/oracle/oradata/ogg/undotbs01.dbf UNDOTBS1
/u01/app/oracle/oradata/ogg/zlm01.dbf ZLM SQL> create user zlm identified by zlm default tablespace zlm; User created. SQL> grant dba to zlm; Grant succeeded.
SQL> conn zlm/zlm
Connected.
SQL> create table zlm.test_charset(
id number,
name varchar2(),
primary key(id)
); Table created. SQL> insert into zlm.test_charset(id,name) values(,'黎明'); row created. SQL> commit; Commit complete. SQL> select * from test_charset; ID NAME
---------- ----------
黎明 SQL> select length('黎'),length('明') from dual; LENGTH('黎') LENGTH('明')
------------ ------------ SQL> select lengthb('黎'),lengthb('明') from dual; LENGTHB('黎') LENGTHB('明')
------------- ------------- //ZHS16GBK character set occupies 2 byte to store one Chinese character here.
//Be aware of the difference of length() function between MySQL and Oracle.
//In MySQL,length() returns bytes instead of characters.
Export the test table with expdp.
 SQL> select *from dba_directories;

 OWNER                   DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS ORACLE_OCM_CONFIG_DIR
/u01/app/oracle/product/11.2./db_1/ccr/state SYS DATA_PUMP_DIR
/u01/app/oracle/admin/ogg/dpdump/ SYS XMLDIR
/u01/app/oracle/product/11.2./db_1/rdbms/xml SQL> create directory datapump as '/u01/'; Directory created. SQL> grant read,write on directory datapump to zlm;
grant read,write on directory datapump to zlm
*
ERROR at line :
ORA-: you may not GRANT/REVOKE privileges to/from yourself SQL> conn / as sysdba
Connected.
SQL> grant read,write on directory datapump to zlm; Grant succeeded. SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option
[oracle@ogg ~]$ expdp zlm/zlm directory=datapump dumpfile=zlm_datapump_`date +%Y%m%d`.dmp logfile=zlm_datapump_`date +%Y%m%d`.log schemas=zlm Export: Release 11.2.0.1. - Production on Wed Jul :: Copyright (c) , , Oracle and/or its affiliates. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option
Starting "ZLM"."SYS_EXPORT_SCHEMA_01": zlm/******** directory=datapump dumpfile=zlm_datapump_20180711.dmp logfile=zlm_datapump_20180711.log schemas=zlm
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 64 KB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/INDEX/INDEX
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type SCHEMA_EXPORT/TABLE/COMMENT
. . exported "ZLM"."TEST_CHARSET" 5.414 KB 1 rows
Master table "ZLM"."SYS_EXPORT_SCHEMA_01" successfully loaded/unloaded
******************************************************************************
Dump file set for ZLM.SYS_EXPORT_SCHEMA_01 is:
/u01/zlm_datapump_20180711.dmp
Job "ZLM"."SYS_EXPORT_SCHEMA_01" successfully completed at 12:51:31 [oracle@ogg ~]$ cd /u01
[oracle@ogg u01]$ ls -l
total 200
drwxrwxr-x 4 oracle oinstall 4096 May 19 2017 app
drwxrwxr-x 3 oracle oinstall 4096 Mar 29 15:40 arch
drwxrwxr-x 14 oracle oinstall 4096 Feb 7 17:01 ogg
-rw-r----- 1 oracle oinstall 184320 Jul 11 12:51 zlm_datapump_20180711.dmp
-rw-r--r-- 1 oracle oinstall 1500 Jul 11 12:51 zlm_datapump_20180711.log
[oracle@ogg u01]$
Modify the character set into "UTF8".
 SQL> alter database character set utf8;
alter database character set utf8
*
ERROR at line :
ORA-: new character set must be a superset of old character set //Notice!This means that UTF8 is not the superset of ZHS16GBK. SQL> alter database character set internal_use utf8;
alter database character set internal_use utf8
*
ERROR at line :
ORA-: operation requires database is in RESTRICTED mode SQL> shutdown immediate
ORA-: insufficient privileges
SQL> conn / as sysdba
Connected.
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount exclusive;
ORACLE instance started. Total System Global Area bytes
Fixed Size bytes
Variable Size bytes
Database Buffers bytes
Redo Buffers bytes
Database mounted.
SQL> alter system enable restricted session; System altered. SQL> alter database open; Database altered. SQL> alter database character set internal_use utf8;
alter database character set internal_use utf8
*
ERROR at line :
ORA-: operation cannot execute when other sessions are active //Exit the other sessions who are active. SQL> alter database character set internal_use utf8; Database altered. SQL>
Check the new database character set.
 SQL> set line  pages
SQL> col value for a40
SQL> select * from nls_database_parameters; PARAMETER VALUE
------------------------------------------------------------ ----------------------------------------
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CHARACTERSET UTF8
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY $
NLS_COMP BINARY
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CONV_EXCP FALSE
NLS_NCHAR_CHARACTERSET AL16UTF16
NLS_RDBMS_VERSION 11.2.0.1. rows selected. SQL> select userenv('language') from dual; USERENV('LANGUAGE')
--------------------------------------------------------------------------------------------------------
AMERICAN_AMERICA.UTF8 SQL>
Check the original data in test table.
 SQL> conn zlm/zlm
Connected.
SQL> select * from test_charset; ID NAME
---------- --------------------
?? //My client character set of Xshell is still GBK now,change it to utf8 and check again. SQL> select * from test_charset; ID NAME
---------- --------------------
?£¿ //The NLS_LANG variable is still GBK,modify the oracle profile to correct the character set to UTF8. SQL> !
[oracle@ogg u01]$ cat ~/.bash_profile|grep NLS_LANG
export NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
[oracle@ogg u01]$ vi ~/.bash_profile
[oracle@ogg u01]$ cat ~/.bash_profile|grep NLS_LANG
export NLS_LANG=AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ . ~/.bash_profile
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ sqlplus zlm/zlm SQL*Plus: Release 11.2.0.1. Production on Wed Jul :: Copyright (c) , , Oracle. All rights reserved. Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option SQL> select * from test_charset; ID NAME
---------- ----------
hķ //It's still messy code here after i've unified the character set with server,client,NLS_LANG.
Drop test user and import it into database with the previous dump file.
 SQL> show user;
USER is "ZLM"
SQL> conn / as sysdba
Connected.
SQL> drop user zlm cascade;
drop user zlm cascade
*
ERROR at line :
ORA-: cannot drop a user that is currently connected SQL> select sid,serial#,status from v$session where username='ZLM'; SID SERIAL# STATUS
---------- ---------- --------
INACTIVE SQL> alter system kill session '1,7'; System altered. SQL> select sid,serial#,status from v$session where username='ZLM'; SID SERIAL# STATUS
---------- ---------- --------
KILLED SQL> drop user zlm cascade; User dropped. SQL> alter user system identified by 'Passw0rd';
alter user system identified by 'Passw0rd'
*
ERROR at line :
ORA-: missing or invalid password(s) SQL> alter user system identified by Passw0rd; User altered. SQL> !
[oracle@ogg u01]$ ls -l
total
drwxrwxr-x oracle oinstall May app
drwxrwxr-x oracle oinstall Jul : arch
drwxrwxr-x oracle oinstall Feb : ogg
-rw-r----- oracle oinstall Jul : zlm_datapump_20180711.dmp
-rw-r--r-- oracle oinstall Jul : zlm_datapump_20180711.log
[oracle@ogg u01]$ impdp system/Passw0rd directory=datapump dumpfile=zlm_datapump_20180711.dmp Import: Release 11.2.0.1. - Production on Wed Jul :: Copyright (c) , , Oracle and/or its affiliates. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option
Master table "SYSTEM"."SYS_IMPORT_FULL_01" successfully loaded/unloaded
Starting "SYSTEM"."SYS_IMPORT_FULL_01": system/******** directory=datapump dumpfile=zlm_datapump_20180711.dmp
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
. . imported "ZLM"."TEST_CHARSET" 5.414 KB 1 rows
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Job "SYSTEM"."SYS_IMPORT_FULL_01" successfully completed at 15:32:56 [oracle@ogg u01]$
Check the data in user zlm again.
 [oracle@ogg u01]$ exit
exit SQL> conn zlm/zlm
ERROR:
ORA-: your session has been killed Connected.
SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option
[oracle@ogg u01]$ sqlplus zlm/zlm SQL*Plus: Release 11.2.0.1. Production on Wed Jul :: Copyright (c) , , Oracle. All rights reserved. Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option SQL> select * from test_charset; ID NAME
---------- --------------------
hķ SQL> select userenv('language') from dual; USERENV('LANGUAGE')
--------------------------------------------------------------------------------
AMERICAN_AMERICA.UTF8 SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.ZHS16GBK //The NLS_LANG is not equal with the character set in database.
[oracle@ogg u01]$ sed -i 's/ZHS16GBK/UTF8/g' ~/.bash_profile
[oracle@ogg u01]$ cat ~/.bash_profile|grep NLS_LANG
export NLS_LANG=AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ . ~/.bash_profile
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ sqlplus zlm/zlm SQL*Plus: Release 11.2.0.1. Production on Wed Jul :: Copyright (c) , , Oracle. All rights reserved. Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option SQL> select * from test_charset; ID NAME
---------- ----------
黎明 SQL> select length('黎'),length('明') from dual; LENGTH('黎') LENGTH('明')
------------ ------------ SQL> select lengthb('黎'),lengthb('明') from dual; LENGTHB('黎') LENGTHB('明')
------------- ------------- SQL> //The character set of database has been changed to UTF8 now and the data is either equal with the orgiginal data.
2. Set database character set from UTF8 to ZHS16GBK.
 
Insert a test record into test_charset table and shutdown instance to change character set again.
 SQL> insert into test_charset values(,'上海');

  row created.

 SQL> commit;

 Commit complete.

 SQL> select * from test_charset;

     ID NAME
---------- ----------
黎明
上海 SQL> select length('上'),length('海') from dual; LENGTH('上') LENGTH('海')
------------ ------------ SQL> select lengthb('上'),lengthb('海') from dual; LENGTHB('上') LENGTHB('海')
------------- ------------- SQL> alter database character set ZHS16GBK;
alter database character set ZHS16GBK
*
ERROR at line :
ORA-: new character set must be a superset of old character set SQL> alter database character set internal_use ZHS16GBK;
alter database character set internal_use ZHS16GBK
*
ERROR at line :
ORA-: operation requires database is in RESTRICTED mode SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup restrict
ORACLE instance started. Total System Global Area bytes
Fixed Size bytes
Variable Size bytes
Database Buffers bytes
Redo Buffers bytes
Database mounted.
Database opened.
SQL> alter database character set internal_use ZHS16GBK; Database altered. SQL> select userenv('language') from dual; USERENV('LANGUAGE')
--------------------------------------------------------------------------------
AMERICAN_AMERICA.ZHS16GBK SQL>
Modify the character set of NLS_LANG togeter with that in client tool such as Xshell in my environment.
 SQL> !
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ sed -i 's/UTF8/ZHS16GBK/g' ~/.bash_profile
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.UTF8
[oracle@ogg u01]$ . ~/.bash_profile
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.ZHS16GBK
[oracle@ogg u01]$ exit
exit SQL> select * from test_charset;
select * from test_charset
*
ERROR at line :
ORA-: table or view does not exist SQL> conn zlm/zlm
Connected.
SQL> select * from test_charset; ID NAME
---------- ------------------------------
姒涘孩妲
娑撳﹥鎹 SQL> //It's messy code now only if you've exported the data with datapump before you change the character set.Unfortunetely,I didn't to that this time.The characters in the test table test_charset has been destroyed.Can it come back again then?
Change it back to utf8 and check what will happen then?
 SQL> alter database character set utf8;
alter database character set utf8
*
ERROR at line :
ORA-: new character set must be a superset of old character set SQL> alter database character set internal_use utf8;
alter database character set internal_use utf8
*
ERROR at line :
ORA-: operation requires connection as SYS //It needs sys role privilege to finish the work. SQL> show user;
USER is "ZLM"
SQL> conn / as sysdba
Connected.
SQL> alter database character set internal_use utf8; Database altered. SQL> select * from zlm.test_charset; ID NAME
---------- ----------
榛庢槑
涓婃捣 SQL> select userenv('language') from dual; USERENV('LANGUAGE')
----------------------------------------------------
AMERICAN_AMERICA.UTF8 //Character set of database server is UTF8 now. SQL> !
[oracle@ogg u01]$ echo $NLS_LANG
AMERICAN_AMERICA.UTF8 //NLS_LANG is UTF8,too.
[oracle@ogg u01]$ //Character set of client tool has been changed to UTF8 as well.But the data cannot show the correct characters anymore.Have they been really destroyed?
Notice,only the user who has sys role privelge  can login instance after using "restrict" mode.See below.
 [oracle@ogg ~]$ sqlplus / as sysdba

 SQL*Plus: Release 11.2.0.1. Production on Wed Jul  :: 

 Copyright (c) , , Oracle.  All rights reserved.

 Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option SQL> create user aaron8219 identified by aaron8219; User created. SQL> grant session,connect to aaron8219;
grant session,connect to aaron8219
*
ERROR at line :
ORA-: role 'SESSION' does not exist SQL> grant connect,resource to aaron8219; Grant succeeded. SQL> conn aaron8219/aaron8219
ERROR:
ORA-: ORACLE only available to users with RESTRICTED SESSION privilege Warning: You are no longer connected to ORACLE.
SQL>

Supplemented on July 12

 SQL> select userenv('language') from dual;

 USERENV('LANGUAGE')
--------------------------------------------------------------------------------------------------------
AMERICAN_AMERICA.UTF8 SQL> select * from zlm.test_charset; ID NAME
---------- --------------------

ʏº£ SQL> !
[oracle@ogg ~]$ echo $NLS_LANG
AMERICAN_AMERICA.ZHS16GBK
[oracle@ogg ~]$ sed -i 's/ZHS16GBK/UTF8/g' .bash_profile
[oracle@ogg ~]$ cat .bash_profile|grep NLS
export NLS_LANG=AMERICAN_AMERICA.UTF8
[oracle@ogg ~]$ . .bash_profile
[oracle@ogg ~]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.1. Production on Thu Jul :: Copyright (c) , , Oracle. All rights reserved. Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1. - 64bit Production
With the Partitioning option SQL> select * from zlm.test_charset; ID NAME
---------- ----------
黎明
上海 SQL> select userenv('language') from dual; USERENV('LANGUAGE')
----------------------------------------------------
AMERICAN_AMERICA.UTF8 SQL> select lengthb('上'),lengthb('海') from dual; LENGTHB('上') LENGTHB('海')
------------- ------------- //Change the character set of client tool to utf8,then the messy code came back again. SQL> select * from zlm.test_charset; ID NAME
---------- ----------
榛庢槑
涓婃捣 SQL> //Actually,the reason why messy code occurs yesterday is due to the discordance between the character set of database,NLS_LANG,client tool.
//Although it proves that the data haven't been destroyed but there's a risk of mismatch of data if you change character set without backing up your whole data.
Summary
  • "internal_use" can help you to change character set without the constraint of subset to superset.
  • Only sys privilege users can login instance while database is running in restrict mode.
  • Be aware of ZHS16GBK is not subset of UTF8.It may baffle us most people.
  • It's not recommeded to change character set in oracle database which contains Chinese characters.
  • Don't forget to backup your data(logically) with datapump before you change the character set.
  • Make your  character set equal in client tool,NLS_LANG,db server anytime.This is the most important thing to keep in mind.
 

谨慎修改Oracle数据库字符集(UTF8<->ZHS16GBK)的更多相关文章

  1. Linux下修改Oracle数据库字符集命令

    常见情形:从服务器备份Oracle数据库后再到本地机器上还原Oracle数据库的时候经常会碰见数据库字符编码不一致的情况,可以用以下命令来修改本地的Oracle数据库字符编码,然后顺利还原Oracle ...

  2. oracle_修改Oracle数据库字符集 AL32UTF8;

    修改数据库字符集 以支持维文等  utf8 停掉库 进入装载模式 ALTER SYSTEM ENABLE RESTRICTED SESSION; ALTER SYSTEM SET JOB_QUEUE_ ...

  3. 修改Oracle数据库的字符集为UTF-8

    1.改客户端字符集:通过WINDOWS的运行菜单运行Regedit,修改注册表 Start -> Run -> Rededit <-| Under registry Editor - ...

  4. 修改oracle数据库的编码为utf-8

    1.查看数据库字符集 ? 数据库服务器字符集select * from nls_database_parameters,其来源于props$,是表示数据库的字符集. 客户端字符集环境select * ...

  5. oracle数据库字符集的修改

    本文摘自:http://blog.csdn.net/nsj820/article/details/65711051.改客户端字符集:通过WINDOWS的运行菜单运行Regedit,修改注册表 Star ...

  6. linux下oracle数据库字符集修改

    linux下oracle数据库字符集修改 0.RHEL6.7.oracle11gr2 1.登录oracle.在安装oracle的用户下进入数据库. $ sqlplus / as sysdba 2.查询 ...

  7. Oracle数据库字符集问题解析

    Oracle数据库字符集问题解析 经常看到一些朋友问ORACLE字符集方面的问题,我想以迭代的方式来介绍一下.第一次迭代:掌握字符集方面的基本概念.有些朋友可能会认为这是多此一举,但实际上正是由于对相 ...

  8. Oracle数据库字符集问题

    Oracle数据库的字符集问题,也涉及作为服务器操作系统的CentOS或者Windows的字符集与Oracle字符集之间的关联关系Oracle的字符集,这个问题的提出是因为两个原因:一是遇到一个DMP ...

  9. 选择ORACLE数据库字符集

    如何选择数据库的字符集是一个有争议的话题,字符集本身涉及的范围很广,它与应用程序.客户的本地环境.操作系统.服务器等关系很密切,因此要做出合适的 选择,需要明白这些因素之间的关系.另外对字符集的基本概 ...

随机推荐

  1. 工作中常用的sql语句以及知识整理

    一.常用的sql语句 1.建表语句 create table tabname(colname1 type1 [not null][primary key], colname2 type2,...) 根 ...

  2. IOS如何下载旧版本应用APP

    前言 文章相对来说比较复杂,特别是查找版本ID对应的步骤,这里推荐使用另一种方案,操作起来更简单. 本文介绍如何使用Workflow及Fiddler下载IOS旧版本APP应用. 实现原理 通过Work ...

  3. 机智的Popup,带着简单的图表感觉酷酷的

    之前有提过用 InfoTemplate 类对 FeatureLayer 的基本信息进行展示,今天为大家介绍 esri/dijit/Popup 的使用,这东西还有 简单的图表展示功能呢! <!DO ...

  4. vs2010开发activex(MFC)控件/ie插件(二):js传参数

    原文:http://blog.csdn.net/yhhyhhyhhyhh/article/details/50802075  js传参数给activex控件. 过程为:js变量通过activex类的属 ...

  5. 使用C3的一些新属性绘制谷歌浏览器的图标

    <!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8&quo ...

  6. Canvas杂谈

    最近在看一些关于Canvas的知识...这篇文章主要是用来记录学习中遇见的一些问题...以及难以理解的一些东西.. 转帖请注明出处:http://www.cnblogs.com/Troy-Lv5/p/ ...

  7. gmock使用、原理及源码分析

    1      初识gmock 1.1      什么是Mock 便捷的模拟对象的方法. 1.2      Google Mock概述 google mock是用来配合google test对C++项目 ...

  8. 最详细的Vue Hello World应用开发步骤

    很多Vue的初学者想尝试这个框架时,都被webpack过于复杂的配置所吓倒,导致最后无法跑出一个期望的hello word效果.今天我就把我第一次使用webpack打包一个Vue Hello Worl ...

  9. mysql 修改已存在的表增加ID属性为auto_increment自动增长

    今天有需要将已经存在表设置自动增长属性 具体如下 alter table customers change id id int not null auto_increment primary key; ...

  10. angular中ngOnChanges与组件变化检测的关系

    1.ngOnChanges只有在输入值改变的时候才会触发,如果输入值(@Input)是一个对象,改变对象内的属性的话是不会触发ngOnChanges的. 2.组件的变化检测: 2a.changeDet ...