Re: Issue with retrieving data when the column has @- in it's value - Mailing list pgsql-admin

From Tom Lane
Subject Re: Issue with retrieving data when the column has @- in it's value
Date
Msg-id 2476401.1743868346@sss.pgh.pa.us
Whole thread Raw
In response to Re: Issue with retrieving data when the column has @- in it's value  (Scott Ribe <scott_ribe@elevated-dev.com>)
List pgsql-admin
Scott Ribe <scott_ribe@elevated-dev.com> writes:
> On Apr 5, 2025, at 9:18 AM, Laurenz Albe <laurenz.albe@cybertec.at> wrote:
>> Also, compare the collations shown in the \l output for the database.

> And glibc versions...

Yeah, that.  This smells very much like a collation-inconsistency
problem: random punctuation is exactly the sort of input that the
glibc authors tend to change collation behaviors for.  I'm betting
that at some point the problematic database was physically copied
between two platforms with inconsistent collations.  (The OP
mentioning use of two different Linux distros bolsters this
theory.)  That made the index inconsistent with the new platform's
sorting behavior, and weird key lookup failures is exactly what
you get as a result of that.

Short answer: REINDEX whatever index the problematic query is
using, as well as any others on text columns, because they
likely have similar issues you haven't noticed yet.

            regards, tom lane



pgsql-admin by date:

Previous
From: Scott Ribe
Date:
Subject: Re: Issue with retrieving data when the column has @- in it's value