Re: 'alternatives' - Mailing list pgsql-general

From Tom Lane
Subject Re: 'alternatives'
Date
Msg-id 18562.1354143015@sss.pgh.pa.us
Whole thread Raw
In response to Re: 'alternatives'  (Andres Freund <andres@anarazel.de>)
List pgsql-general
Andres Freund <andres@anarazel.de> writes:
> The commit introducing this is:
> http://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=bd3daddaf232d95b0c9ba6f99b0170a0147dd8af
> What that does to add hashing support for IN(). But hashing can be
> pessimal in comparison to a explicit check if only a few values come in,
> so this can be checked at runtime after the above commit...

Yeah.  If you look at the subplans, one is designed for retail probes
and the other is designed for sucking up the entire subquery result into
a hashtable.  EXPLAIN ANALYZE will show you that only one gets used at
runtime.  (The idea of dynamic switchover hasn't gotten anywhere yet.)

            regards, tom lane


pgsql-general by date:

Previous
From: Thomas Kellerer
Date:
Subject: Updateable VIEWS and the manual
Next
From: Tom Lane
Date:
Subject: Re: pg_listening_channels()