472,096 Members | 1,184 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,096 software developers and data experts.

Please Help with libpq and unicode

Hey all,

First off I am new to postgres and multi-lingual development so pardon me if
the answer is overly obvious.

We our database is setup for UNICODE. We have a mixture of clients
accessing the database through JDBC and C (libpq). My question involves the
C interface to Postgres libpq.

Once a query has been made (with client_connection set to unicode) I need to
get the data from result object using PQgetvalue(). PQgetvalue returns a
char*. There is some documentation about testing to see if the data is
binary and then casting it to the appropriate type. No where did it mention
the handling of unicode data.

So if I am executing PQgetvalue and I am expecting a unicode string what do
I have to do to get to the unicode data? cast it? convert it with a
utility?

An example would be greatly appreciated.

Thanks in advance

--
Every Time I close My Eyes
There is another vivid surprise
Another whole life waiting ...
Chapters unfinished, fading
--- Scenes From A Memory ---

Nov 23 '05 #1
0 2297

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Dan Thibault | last post: by
reply views Thread by Timo Virkkala | last post: by
1 post views Thread by Phil Campaigne | last post: by
9 posts views Thread by Christian Wetzig | last post: by
1 post views Thread by Robert Fitzpatrick | last post: by
2 posts views Thread by alltest1 | last post: by
1 post views Thread by ekzept | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.