Unix Technical Forum

Re: UICODE SUPPORT IN 8.00.0102

This is a discussion on Re: UICODE SUPPORT IN 8.00.0102 within the pgsql Interfaces odbc forums, part of the PostgreSQL category; --> I had the same problem with Win2k. The database encoding is UNICODE. Reading with SET CLIENT_ENCODING=UNICODE worked, but writing ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Interfaces odbc

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-16-2008, 01:19 AM
Josef Springer
 
Posts: n/a
Default Re: UICODE SUPPORT IN 8.00.0102

I had the same problem with Win2k. The database encoding is UNICODE.
Reading with SET CLIENT_ENCODING=UNICODE worked, but writing did not
work. In ODBC 8.00.01.01 may be a problem with encoding on Win2k and
Win98. WinXP works well.

Josef Springer


CHEN wrote:

> server encoding : EUC_CN
> client: PSQLODBC8.00.0102 +WIN98
>
> When I select some chinese characters from sever, these characters
> display '?????'.
>
> SHOW CLIENT_ENCODING ----- EUC_CN
>
> SET CLIENT_ENCODING=UNICODE, Then characters display normal.
>
> So I need add this setting every time when connecting.
> But it don't nedd in psqlodbc8.00.0101.
>
> I think it is a bug:
> connetcion.c(download from src psqlodbc8.00.0102) line 1025:
>
> --------------------------------------------------------
> if (!self->client_encoding ||!stricmp(self->client_encoding, "UNICODE"))
> {
> CLIENT_ENDONG CHANGE TO UNICODE....
> --------------------------------------------------------
>
> should be(8.00.0101):
> --------------------------------------------------------
> if (!self->client_encoding ||stricmp(self->client_encoding, "UNICODE"))
> /*WHEN CLIENT_ENCODING IS NOT UNICODE ,THEN CHANGE TO UNICODE */
> {
> CLIENT_ENDONG CHANGE TO UNICODE....
>
> --------------------------------------------------------
>
> psqlodbc8.00XX is unicode version, ODBC level is working on unicode,
> so ODBC must set client_encodding to unicode only when connectting,
> ODBC muet prevent application from setting client_encodding to other
> encodding, and ODBC level transfer to application level using FUNCTION
> "utf8-->UCS2" AND "WideCharToMultiByte"
>
>
>
>
>
> 需要一个2000兆的免费邮箱吗?
> 网易免费邮箱是中国最多人使用的电子邮箱。 <http://mail.163.com>
>


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 04:25 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com