On Thu, May 23, 2013 at 12:21 PM, <fburgess@radiantblue.com> wrote:
>
> But what negative impact is disabling hash joins?
>
doing it just for a single query, could be a tool for solving
particular problems.
setting it in postgresql.conf, therefore affecting all queries, is
like using a hammer to change tv channel... it will cause more
problems than the one it solves.
what you can do is:
1) execute:
SET enable_hashjoin TO OFF;
SELECT here
RESET enable_hashjoin TO ON;
2) in a function:
CREATE FUNCTION do_something() RETURNS bigint AS
$$
SELECT here
$$ LANGUAGE sql SET enable_hashjoin TO OFF STABLE;
--
Jaime Casanova www.2ndQuadrant.com
Professional PostgreSQL: Soporte 24x7 y capacitación
Phone: +593 4 5107566 Cell: +593 987171157