Re: Understanding Hash Join performance - Mailing list pgsql-performance

From Robert Haas
Subject Re: Understanding Hash Join performance
Date
Msg-id BANLkTinV-YghC9_UfoDJmjmji5DsMww8Qw@mail.gmail.com
Whole thread Raw
In response to Understanding Hash Join performance  (Robert James <srobertjames@gmail.com>)
List pgsql-performance
On Wed, Jun 1, 2011 at 8:10 PM, Robert James <srobertjames@gmail.com> wrote:
> A query I has spends a long time on Hash Joins (and Hash Left Joins).
> I have a few questions:
>
> 1. When does Postgres decide to do a Hash Join, over another type of Join?
> 2. Do Hash Joins normally perform poorly?  What can I do to speed them up?
> 3. What can I do to enable Postgres to use a faster type of join?

IME, hash joins usually are much faster than any other type.  There's
not enough information in your email to speculate as to what might be
going wrong in your particular case, though.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

pgsql-performance by date:

Previous
From: Claudio Freire
Date:
Subject: Re: Understanding Hash Join performance
Next
From: "Kevin Grittner"
Date:
Subject: Re: Problem query