From: Zhang, Hongyan <ZhangH3@aetna.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@lists.postgresql.org <pgsql-bugs@lists.postgresql.org>
Subject: Re: [EXTERNAL] Re: BUG #16835: btree index does not work for where clause using 'foo%'
Date: Fri, 22 Jan 2021 19:07:22 +0000
Message-ID: <E75956AF-B8FD-49AC-A9DD-A503F26F4AA2@aetna.com> (raw)
In-Reply-To: <1165678.1611333843@sss.pgh.pa.us>
References: <16835-419ddd12f1e74ee5@postgresql.org>
<1165678.1611333843@sss.pgh.pa.us>
Thanks, Tom.
Locale is en_US.UTF-8.
Is there plan to alter that behavior to allow index in non C locale?
From: Tom Lane <tgl@sss.pgh.pa.us>
Date: Friday, January 22, 2021 at 10:52 AM
To: "Zhang, Hongyan" <ZhangH3@aetna.com>
Cc: "pgsql-bugs@lists.postgresql.org" <pgsql-bugs@lists.postgresql.org>
Subject: [EXTERNAL] Re: BUG #16835: btree index does not work for where clause using 'foo%'
**** External Email - Use Caution ****
PG Bug reporting form <noreply@postgresql.org> writes:
> https://www.postgresql.org/docs/11/indexes-types.html<https://www.postgresql.org/docs/11/indexes-...;, according to this
> page, btree index is supposed to work for where clause col like 'foo%', but
> does not work for me. we are on aurora postgres 11, I also tested on
> postgres 11, it does not work either.
As the manual explains, that will not work by default unless your
database locale is C (which is an uncommon default nowadays).
It's also possible that Aurora has changed something that keeps
it from working, but I'd investigate the locale angle first.
regards, tom lane
NOTICE TO RECIPIENT OF INFORMATION:
This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately.
This e-mail may also contain protected health information (PHI) with information about sensitive medical conditions, including, but not limited to, treatment for substance use disorders, behavioral health, HIV/AIDS, or pregnancy. This type of information may be protected by various federal and/or state laws which prohibit any further disclosure without the express written consent of the person to whom it pertains or as otherwise permitted by law. Any unauthorized further disclosure may be considered a violation of federal and/or state law. A general authorization for the release of medical or other information may NOT be sufficient consent for release of this type of information.
Thank you. Aetna
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-bugs@postgresql.org
Cc: ZhangH3@aetna.com, tgl@sss.pgh.pa.us
Subject: Re: [EXTERNAL] Re: BUG #16835: btree index does not work for where clause using 'foo%'
In-Reply-To: <E75956AF-B8FD-49AC-A9DD-A503F26F4AA2@aetna.com>
References: <16835-419ddd12f1e74ee5@postgresql.org> <1165678.1611333843@sss.pgh.pa.us> <E75956AF-B8FD-49AC-A9DD-A503F26F4AA2@aetna.com>
* 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