[pgsql-jp: 38219] Codepage of EUC_jp is 20932
ITAGAKI Takahiro
itagaki.takahiro @ oss.ntt.co.jp
2007年 3月 26日 (月) 11:02:26 JST
I found a bug in the definition of EUC_jp codepage.
20932 should be used here instead of 51932. (MSDN might be wrong!)
If we choose EUC_jp as a encoding and 'Japanese, Japan' as a locale,
pginstaller tries to set 'Japanese_Japan.51932' and fails.
Then it sets 'Japanese_Japan' (without locale),
but it means 'Japanese_Japan.932' (SJIS).
The mismatch of server encoding and locale encoding causes problems.
It might be better to check the locale encoding more strictly.
setlocale(LC_COLLATE, "Japanese_Japan") -> OK (Japanese_Japan.932)
setlocale(LC_COLLATE, "Japanese_Japan.932") -> OK
setlocale(LC_COLLATE, "Japanese_Japan.20932") -> OK
setlocale(LC_COLLATE, "Japanese_Japan.51932") -> ERROR
Regards,
---
ITAGAKI Takahiro
pgsql-jp メーリングリストの案内