364,111 Members | 2029 Browsing Online
Community for Developers & IT Professionals
Bytes IT Community

Get UNICODE data using libpq

gouse
P: 18
Hi All,

I am using libpq 'C' interface to connect to the PostgreSQL database. The encoding of Database is UTF8 and it also contains a table with UNICODE data. By using PQconnectdb() I have made a connection with the database, Next I have also set the PGSetClientEncoding() to UTF8, After this I am executing the select query using PQexec() command, but it was not giving the UNICODE data. Is there any step I am missing?

By using the ODBC Driver9(UNICODE not ANSI) I made a connection to the same database and executed the same select query, here it was giving me the UNICODE data properly.

Please let me know how to get the UNICODE data using the libpq Interface.

Thanks & Regards
Gouse Shaik
Dec 27 '11 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Help answer this question



Didn't find the answer to your PostgreSQL Database question?

You can also browse similar questions: PostgreSQL Database