Re: nbtree's ScalarArrayOp array mark/restore code appears to be buggy
Peter Geoghegan <pg@bowt.ie>
From: Peter Geoghegan <pg@bowt.ie>
To: PostgreSQL Hackers <pgsql-hackers@postgresql.org>,
Tom Lane <tgl@sss.pgh.pa.us>
Date: 2023-09-25T17:33:22Z
Lists: pgsql-hackers
On Sat, Sep 23, 2023 at 4:22 PM Peter Geoghegan <pg@bowt.ie> wrote: > Attached draft patch shows how this could work. > > _bt_restore_array_keys() has comments that seem to suppose that > calling _bt_preprocess_keys is fairly expensive, and something that's > well worth avoiding. But...is it, really? I wonder if we'd be better > off just biting the bullet and always calling _bt_preprocess_keys > here. My current plan is to commit something close to my original patch on Wednesday or Thursday. My proposed fix is minimally invasive (it still allows _bt_restore_array_keys to avoid most calls to _bt_preprocess_keys), so I don't see any reason to delay acting here. -- Peter Geoghegan
Commits
-
Fix btmarkpos/btrestrpos array key wraparound bug.
- 714780dcddf0 17.0 landed
- 3fa81b62e09b 16.1 landed
- cac37c1a1b7c 15.5 landed
- 41486c4aaeb1 14.10 landed
- d4724e94a1eb 13.13 landed
- b36d72cbc6b0 12.17 landed
- 7c07305e6f02 11.22 landed
-
Fix btmarkpos/btrestrpos to handle array keys.
- 70bc5833195d 9.3.0 cited