Becky Neville wrote:
> Here is the EXPLAIN output from the two queries. The first is the one
> that uses WHERE field NOT IN ( 'a','b' etc ). The second is the (much
Unless you are working with Postgres 7.4devel (i.e. cvs HEAD), the IN
construct is notoriously slow in Postgres. In cvs it is vastly improved.
Also, as I mentioned in the other reply, send in "EXPLAIN ANALYZE"
results instead of "EXPLAIN" (and make sure you run "VACUUM ANALYZE" first).
Joe