Skip site navigation (1) Skip section navigation (2)

Re: unicode and libpq

From: Christoph Haller <ch(at)rodos(dot)fzk(dot)de>
To: pgsql-interfaces(at)postgresql(dot)org, dzemik(at)venco(dot)com(dot)pl
Subject: Re: unicode and libpq
Date: 2003-08-05 15:03:59
Message-ID: 3F2FC75F.572CC891@rodos.fzk.de (view raw or flat)
Thread:
Lists: pgsql-interfaces
>
> How can I put an UNICODE string with characters which code numbers I
> know, ie. "0x00e9 0x00f1"? When I put that string to SQL query,
> interpeter stops with the first 0x00 code. Any ideas? I have trying
with
> UNICODE and LATIN2 client_encoding.
>
>From the subject of your message I assume you're using libpq.
Within libpq you cannot deal with strings containing '\0' resp. 0x00
without processing them through PQescapeBytea.

See
1.3.3. Escaping binary strings for inclusion in SQL queries

HTH

Regards, Christoph



pgsql-interfaces by date

Next:From: D'Arcy J.M. CainDate: 2003-08-05 16:44:15
Subject: Re: Seeking PyGreSQL help
Previous:From: Alastair G. HoggeDate: 2003-08-05 12:53:37
Subject: Re: Seeking PyGreSQL help

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group