Re: [PERFORM] Performance of IN (...) vs. = ANY array[...]

2006-09-15 Thread Tom Lane
Benjamin Minshall <[EMAIL PROTECTED]> writes: > What are the advantages or disadvantages of using arrays in this > situation? The = ANY array method makes plpgsql development cleaner, > but seems to really lack performance in certain cases. In existing releases, the form with IN (list-of-scalar

[PERFORM] Performance of IN (...) vs. = ANY array[...]

2006-09-15 Thread Benjamin Minshall
Greetings: I'm running 8.1.4, and have noticed major differences in execution time for plpgsql functions running queries that differ only in use of an array such as: slower_function( vals integer[] ) [query] WHERE id = ANY vals; faster_function( vals integer[] ) vals_text :