R: [pgsql-zh-general] (solved - 谢谢) Chinese in Postgres

Lists: pgsql-hackersPostg토토 사이트 추천SQLpgsql-zh-general
From: "ciifrancesco(at)tiscali(dot)it" <ciifrancesco(at)tiscali(dot)it>
To: <bambo(dot)huang(at)gmail(dot)com>
Cc: <pgsql-hackers(at)postgresql(dot)org>, <pgsql-zh-general(at)postgresql(dot)org>, <pgsql-ru-general(at)postgresql(dot)org>
Subject: R: [pgsql-zh-general] (solved - 谢谢) Chinese in Postgres
Date: 2013-08-21 10:56:11
Message-ID: 12473813.30981377082571367.JavaMail.defaultUser@defaultHost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers Postg토토 사이트 추천SQL pgsql-zh-general


Eureka.
The problem is solved.

Bambo:
> I guess you forget to convert
you string to utf-8 before insert.

No, too many conversions :)

The
fact is that in the source code the query was casted to UnicodeString,
because of previous requirements on the project:

//tmp is a char* and
contains the query
uniQueryStr = UnicodeString(tmp); //useless

executeMyQuery(uniQueryStr); //this is wrong!!
executeMyQuery(tmp);
//that's right :). TODO never use UnicodeString anymore...

I already
tried to avoid that cast, but when the target was compiled on the Linux
server (that's why i used putty) the executable was not overwritten,
for some weird reason.
So the executable was not 100% according to the
source code; I was always used to compile code with Visual studio or
Eclipse so i wasn't aware of such possibility.
To make it working, I
just removed all the old files and made a long, full and fresh build.

Sorry for making you loose time.

XieXie / 谢谢,
Francesco

Invita i tuoi amici e Tiscali ti premia! Il consiglio di un amico vale più di uno spot in TV. Per ogni nuovo abbonato 30 € di premio per te e per lui! Un amico al mese e parli e navighi sempre gratis: http://freelosophy.tiscali.it/