Yes! "set join_collapse_limit = 9" was enough to fix the plan, thanks Laurenz.
I will set both to 11.
Original Message
From: Laurenz Albe [mailto:laurenz.a...@cybertec.at]
Sent: Thursday, April 11, 2024 at 14:21 UTC
To: ilya Basin; pgsql-general@lists.postgresql.o
id=3)`
Ilya Basin schrieb am 09.03.2024 um 20:08:
Hi List.
I have a list of bigint keys and I need to retrieve rows by these keys.
Normally, I would split this list into pages of size 900 and perform several
`SELECT ... WHERE key in($1,$2,...)`. However, the proprietary ORM we use can
only produce
Hi List.
I have a list of bigint keys and I need to retrieve rows by these keys.
Normally, I would split this list into pages of size 900 and perform several
`SELECT ... WHERE key in($1,$2,...)`. However, the proprietary ORM we use can
only produce this SQL: `SELECT ... WHERE (key=$1 or key=$2