By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
431,943 Members | 1,890 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 431,943 IT Pros & Developers. It's quick & easy.

Get UNICODE data using libpq

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

Sign in to post your reply or Sign up for a free account.