From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Alban Hertroys <alban(at)magproductions(dot)nl> |
Cc: | Postgres general mailing list <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: How to manually insert an UTF-8 character into an SQL statement? |
Date: | 2005-01-20 15:22:41 |
Message-ID: | 20050120152236.GC12585@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Thu, Jan 20, 2005 at 02:48:40PM +0100, Alban Hertroys wrote:
> I'm trying to insert a record that contains an ô (o circumflex) into a
> table using the psql client.
> I also tried with phppgadmin and pgadmin, but both can't do this. They
> insert a HTML entity and error out respectively. Not what I had in mind...
My guess is that the \0x00 is being expanded to a null. If you want a
circumflex, why not just set the encoding to "latin9" or whatever and
send it normally. Unicode characters don't have embedded nulls iirc so
that can't be a properly encoded character anyway...
> Supposedly I should be able to type:
> INSERT INTO table (name) VALUES ('C\0x00f4te d''Azur');
> but all I manage to achieve is inserting a capital 'C'...
Hope this helps,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.
From | Date | Subject | |
---|---|---|---|
Next Message | leon-pg | 2005-01-20 15:34:55 | "Invalid message format" error from JDBC driver |
Previous Message | Joshua D. Drake | 2005-01-20 14:42:08 | Re: Best Linux Distribution |