1、查询数据库的编码集Oracle,MySQL
1.1、oracle
select * from v$nls_parameters where parameter='NLS_CHARACTERSET';
查询版本:SELECT * FROM v$version
2、MySQL编码集
SELECT DEFAULT_CHARACTER_SET_NAME, DEFAULT_COLLATION_NAME FROM information_schema.SCHEMATA WHERE SCHEMA_NAME = 'demo_cg';