aboutsummaryrefslogtreecommitdiff
path: root/src/tutorial/funcs.source
diff options
context:
space:
mode:
authorPeter Geoghegan <pg@bowt.ie>2024-04-07 14:15:54 -0400
committerPeter Geoghegan <pg@bowt.ie>2024-04-07 14:15:54 -0400
commit473411fc51157e8e825ee865c2822f976e0da5e3 (patch)
tree74485a23ac87b0c9c75913880f1b127a15bf3a50 /src/tutorial/funcs.source
parenta475a2fa3bc9c68eaa2aeda28d6d86529eda4673 (diff)
downloadpostgresql-473411fc51157e8e825ee865c2822f976e0da5e3.tar.gz
postgresql-473411fc51157e8e825ee865c2822f976e0da5e3.zip
Avoid extra lookups with nbtree array inequalities.
nbtree index scans with SAOP inequalities (but no SAOP equalities) performed extra ORDER proc lookups for any remaining equality strategy scan keys. This could waste cycles, and caused assertion failures. Keeping around a separate ORDER proc is only necessary for a scan's non-array/non-SAOP equality scan keys when the scan has at least one other SAOP equality strategy key (a SAOP inequality shouldn't count). To fix, replace _bt_preprocess_array_keys_final's assertion with a test that makes the function return early when the scan has no SAOP equality scan keys. Oversight in commit 1b134ca5, which enhanced nbtree ScalarArrayOp execution. Reported-By: Alexander Lakhin <exclusion@gmail.com> Discussion: https://postgr.es/m/0539d3d3-a402-0a49-ed5e-26429dffc4bd@gmail.com
Diffstat (limited to 'src/tutorial/funcs.source')
0 files changed, 0 insertions, 0 deletions