pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix planner's test for case-foldable characters in ILIKE with IC
Date: Mon, 12 Aug 2019 17:16:13 +0000
Message-ID: <E1hxDvZ-00048V-Vd@gemulon.postgresql.org> (raw)

Fix planner's test for case-foldable characters in ILIKE with ICU.

As coded, the ICU-collation path in pattern_char_isalpha() failed
to consider regular ASCII letters to be case-varying.  This led to
like_fixed_prefix treating too much of an ILIKE pattern as being a
fixed prefix, so that indexscans derived from an ILIKE clause might
miss entries that they should find.

Per bug #15892 from James Inform.  This is an oversight in the original
ICU patch (commit eccfef81e), so back-patch to v10 where that came in.

Discussion: https://postgr.es/m/15892-e5d2bea3e8a04a1b@postgresql.org

Branch
------
REL_10_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/886cf85b52cfdd84c0ff9b24193c7e0e0035b1c7

Modified Files
--------------
src/backend/utils/adt/selfuncs.c               | 10 ++++----
src/test/regress/expected/collate.icu.utf8.out | 32 ++++++++++++++++++++++++++
src/test/regress/sql/collate.icu.utf8.sql      |  9 ++++++++
3 files changed, 47 insertions(+), 4 deletions(-)



view thread (4+ messages)  latest in thread

Message-ID: <E1hxDvZ-00048V-Vd@gemulon.postgresql.org>
Permalink:  ../E1hxDvZ-00048V-Vd@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1hxDvZ-00048V-Vd@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Fix planner's test for case-foldable characters in ILIKE with IC
  In-Reply-To: <E1hxDvZ-00048V-Vd@gemulon.postgresql.org>
  References: <E1hxDvZ-00048V-Vd@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox