Skip site navigation (1) Skip section navigation (2)

Re: BUG #4264: Optimizer fails to use hash_aggregate when appropriate.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Scott Carey" <scott(at)richrelevance(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4264: Optimizer fails to use hash_aggregate when appropriate.
Date: 2008-06-25 20:55:55
Message-ID: 23377.1214427355@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
"Scott Carey" <scott(at)richrelevance(dot)com> writes:
> The query optimizer fails to use a hash aggregate most of the time.  This is
> an inconsistent behavior.

Hash aggregation is not used when a DISTINCT aggregate is specified.
DISTINCT forces a sort, so there wouldn't be any advantage.

> Of course DB hints would solve this.

No, they wouldn't.

			regards, tom lane

In response to

Responses

pgsql-bugs by date

Next:From: Bruce MomjianDate: 2008-06-26 01:12:09
Subject: Re: [BUGS] BUG #4128: The postmaster.opts.default file is begin ignored
Previous:From: Scott CareyDate: 2008-06-25 18:00:33
Subject: BUG #4264: Optimizer fails to use hash_aggregate when appropriate.

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group