On 10/4/24 22:00, Peter Geoghegan wrote:
I don't think that removing duplicated constants is all that
important, since we already do that during execution proper. The
nbtree code does this in _bt_preprocess_array_keys. It even does
things like merge together a pair of duplicate SAOPs against the same
column. It doesn't matter if the arrays are of different types,
either.Hmm, my intention is a bit different - removing duplicates allows us to
estimate selectivity more precisely, right? Maybe it is not enough to be a core feature, but I continue to think about auto-generated queries and extensions that can help generate proper plans for queries from AI, ORM, etc. users.

--
regards, Andrei Lepikhov



Reply via email to