Re: BUG #15285: Query used index over field with ICU collation in some cases wrongly return 0 rows

From: Jehan-Guillaume de Rorthais <jgdr(at)dalibo(dot)com>
To: Peter Geoghegan <pg(at)bowt(dot)ie>
Cc: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Роман Литовченко <roman(dot)lytovchenko(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: BUG #15285: Query used index over field with ICU collation in some cases wrongly return 0 rows
Date: 2020-08-18 16:02:46
Message-ID: 20200818180246.04e47f8e@firost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi Peter,

On Tue, 11 Aug 2020 21:14:03 -0700
Peter Geoghegan <pg(at)bowt(dot)ie> wrote:

> On Fri, Jun 12, 2020 at 3:43 PM Jehan-Guillaume de Rorthais
> <jgdr(at)dalibo(dot)com> wrote:
> > Please, find in attachment the second version of the patch, with a
> > regression test.
>
> Is it possible to fix this by making the existing
> HAVE_UCOL_STRCOLLUTF8 test more conservative about ICU version? IOW,
> by making it only use ucol_strcollUTF8() on versions that are known to
> not be affected by this bug?

I might be missing something, but according to my tests back in June, the bug
exists in both ucol_strcollUTF8()/ucol_strcoll() and is still affecting the very
last version of ICU (67.1).

That's why my patch replaces both functions altogether using ucol_strcollIter
as replacement.

> This related ICU bug describes an issue affecting only versions 53/54:
>
> https://unicode-org.atlassian.net/browse/ICU-11388

This bug is related to ICU4J, not ICU4C. AS far as I understand, this was
related to a bad variable type when porting the code to java. Do I miss
something?

Regards,

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Michael Schanne 2020-08-18 16:06:56 RE: BUG #16461: Segfault in autovacuum process
Previous Message Magnus Hagander 2020-08-18 14:25:00 Re: BUG #16584: could not create relation-cache initialization file "global/pg_internal.init.2002": No space left