Received: from mailhub5.isdnet.net (mailhub5.isdnet.net [195.154.209.25]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9SBmKP12098 for ; Sun, 28 Oct 2001 06:48:21 -0500 (EST) (envelope-from jm.poure@freesurf.fr) Received: from station ([195.154.28.3]) by mailhub5.isdnet.net (8.9.3/8.9.3) with ESMTP id MAA31155; Sun, 28 Oct 2001 12:44:29 +0100 (CET) Message-Id: <4.2.0.58.20011028121057.00d1a100@pop.freesurf.fr> X-Sender: jm.poure@pop.freesurf.fr X-Mailer: QUALCOMM Windows Eudora Pro Version 4.2.0.58 Date: Sun, 28 Oct 2001 12:44:26 +0100 To: Marko Kreen From: Jean-Michel POURE Subject: Re: UNICODE Cc: pgsql-hackers@postgresql.org In-Reply-To: <20011028125354.A13053@l-t.ee> References: <4.2.0.58.20011028085953.00cfa740@pop.freesurf.fr> <4.2.0.58.20011028085953.00cfa740@pop.freesurf.fr> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1"; format=flowed Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by postgresql.org id f9SC1YM15164 X-Archive-Number: 200110/981 X-Sequence-Number: 14704 I only want this query to work under Unicode: SELECT * FROM test WHERE source_content ILIKE '%accepté%'. >* If client_encoding == server_encoding, the bytes are put into > DB as-is - no conversion is done. > >So are you absolutely sure you have on client side UTF8 strings? PostgreSQL is compiled with UNICODE and LOCALE support. Unicode is used on both ends (PostgreSQL and psql). >Unfortunately you cant use client_encoding=latin1 as PostgreSQL >refuses the do the conversion between them. (I am with 7.1.3) According to the on-line manual, only MULE provides instant transcoding. >Eg. I did the following: > >* created db with encoding = UNICODE >* Put your example into test.sql >* iconv -f latin1 -t utf8 test.sql > test2.sql >* psql < test2.sql > >and it worked as it should... Nice to hear it works when transcoding files to UTF-8. It shows it is not a back-end problem. As for me, I typed INSERT INTO source_content VALUES ('Permis de conduire accepté') in Psql. Psql does not insert the data and I have to kill it manually. Can you reproduce this? Best regards, Jean-Michel POURE