From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Jeff Davis <pgsql(at)j-davis(dot)com> |
Cc: | Peter Eisentraut <peter(at)eisentraut(dot)org>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: should check collations when creating partitioned index |
Date: | 2023-11-17 20:18:57 |
Message-ID: | 758153.1700252337@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Jeff Davis <pgsql(at)j-davis(dot)com> writes:
> In the patch, you check for an exact collation match. Considering this
> case only depends on equality, I think it would be correct if the
> requirement was that (a) both collations are deterministic; or (b) the
> collations match exactly.
You keep harping on this idea that we are only concerned with equality,
but I think you are wrong. We expect a btree index to provide ordering
not only equality, and this example definitely is a btree index.
Possibly, with a great deal more specificity added to the check, we
could distinguish the cases where ordering can't matter and allow
collation variance then. I do not see the value of that, especially
not when measured against the risk of introducing subtle bugs.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2023-11-17 20:35:52 | Re: Recovering from detoast-related catcache invalidations |
Previous Message | Andres Freund | 2023-11-17 20:13:34 | Re: simplehash: preserve consistency in case of OOM |