Re: should check collations when creating partitioned index
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter Eisentraut <peter@eisentraut.org>
Cc: Laurenz Albe <laurenz.albe@cybertec.at>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2023-11-20T16:25:33Z
Lists: pgsql-hackers
Peter Eisentraut <peter@eisentraut.org> writes: > On 14.11.23 17:15, Tom Lane wrote: >> I don't love the patch details though. It seems entirely wrong to check >> this before we check the opclass match. > Not sure why? The order doesn't seem to matter? The case that was bothering me was if we had a non-collated type versus a collated type. That would result in throwing an error about collation mismatch, when complaining about the opclass seems more apropos. However, if we do this: > I see. That means we shouldn't raise an error on a mismatch but just do > if (key->partcollation[i] != collationIds[j]) > continue; it might not matter much. regards, tom lane
Commits
-
Check collation when creating partitioned index
- 5d40b3c4f6ca 12.18 landed
- 3c49fa2aff2c 13.14 landed
- e846fc491923 14.11 landed
- 15d485921b1c 15.6 landed
- 267f33f68417 16.2 landed
- a11c9c42ea31 17.0 landed