Fix order of parameters in BRIN minmax-multi calls
Tomas Vondra <tomas.vondra@postgresql.org>
Fix order of parameters in BRIN minmax-multi calls The BRIN minmax-multi consistent function incorrectly assumed it can lookup an operator, and then swap the arguments to get the commutator. For example <(a,b) would be called as <(b,a) to get >(a,b). This works when the arguments are of the same type, but with cross-type opclasses this fails. We can't swap <(float4,float8) arguments, for example. Fixed by passing arguments in the right order. Discussion: https://postgr.es/m/CAJKUy5jLZFLCxyxfT%3DMfK5mtPfSzHA1rVLowR-j4RRsFVvKm7A%40mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/access/brin/brin_minmax_multi.c | modified | +4 −4 |
Discussion
- Crash in BRIN minmax-multi indexes 25 messages · 2021-03-31 → 2022-12-30