PL\SQL 查询中文乱码

1 select * from v$nls_parameters
查询nls的参数,获得数据库服务器端的字符编码
PARAMETER VALUE 
[color=red]1 NLS_LANGUAGE AMERICAN [/color]
2 NLS_TERRITORY AMERICA 
3 NLS_CURRENCY $ 
4 NLS_ISO_CURRENCY AMERICA 
5 NLS_NUMERIC_CHARACTERS ., 
6 NLS_CALENDAR GREGORIAN 
7 NLS_DATE_FORMAT DD-MON-RR 
8 NLS_DATE_LANGUAGE AMERICAN 
9 NLS_CHARACTERSET US7ASCII 
10 NLS_SORT BINARY 
11 NLS_TIME_FORMAT HH.MI.SSXFF AM 
12 NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM 
13 NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR 
14 NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR 
15 NLS_DUAL_CURRENCY $ 
16 NLS_NCHAR_CHARACTERSET AL16UTF16 
17 NLS_COMP BINARY 
18 NLS_LENGTH_SEMANTICS BYTE 
19 NLS_NCHAR_CONV_EXCP FALSE 

2 打开 regedit,找到 HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HOME0
设置NLS_LANG=AMERICAN就可以了

你可能感兴趣的:(oracle,sql)