Unicode collation error.

From: Peter Figuli <peposh(at)peposh(dot)sk>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Unicode collation error.
Date: 2002-07-02 16:11:06
Message-ID: 1025626266.23160.17.camel@peposh
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Dear postgres team.
I'm not member of any of your list, but I decided to send this bugreport
since focusing same problem for more than 2 releases of PGSQL. I'm
running Linux-box 2.4.18 kernel, postgres build from your sources-7.2.1.
Steps:
1. Set locales to any UTF-8 one. Do not forget LC_COLLATE because 8-bit
collate do not produce bug.
2. Initdb database, create any table containing text field, and try
this:
SELECT name from state WHERE name like 'z%';
With any UTF-8 locale I got 'Invalid UNICODE character message...'

I was trying to trap a bug and this is my simple description.
An Error occures while testing if string is really multibyte.
Going deeper I found out, that
/src/backend/utils/atd/selfuncs.c on line 2985 (make_greater_string):
there is loop trying create greater string incrementing last byte. This
actually works fine until 0xC0 is not reached, then multibyte checker
fails. Simple hack to margin value to 128 in multibyte works now fine,
but I understand that problem is more complex there and needs probably
deeper look and solution.

Nice day

Peposh

Browse pgsql-bugs by date

  From Date Subject
Next Message Peter Figuli 2002-07-02 16:21:33 JDBC and BigDecimal problem
Previous Message Tom Lane 2002-07-02 14:39:52 Re: psql 7.2.1: \d (alone) missing from \?