pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Rajesh Kumar Mallah <mallah@trade-india.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-admin@postgresql.org
Subject: Re: weired behavior... after pg_resetxlog-> dump->initdb-->reload.
Date: Wed, 16 Jun 2004 21:24:06 +0530
Message-ID: <40D06D1E.5000803@trade-india.com> (raw)
In-Reply-To: <22477.1087400110@sss.pgh.pa.us>
References: <40CFFC68.5090704@trade-india.com>
	<21524.1087394109@sss.pgh.pa.us>
	<40D06096.90200@trade-india.com>
	<22477.1087400110@sss.pgh.pa.us>


Dear Tom,

It does.


rt2=# explain SELECT name from users_sample group by name having 
count(*) > 1 ;
+-----------------------------------------------------------------------+
|                              QUERY PLAN                               |
+-----------------------------------------------------------------------+
| HashAggregate  (cost=25.00..26.00 rows=200 width=78)                  |
|   Filter: (count(*) > 1)                                              |
|   ->  Seq Scan on users_sample  (cost=0.00..20.00 rows=1000 width=78) |
+-----------------------------------------------------------------------+
(3 rows)

Time: 375.619 ms
rt2=# explain analyze SELECT name from users_sample group by name having 
count(*) > 1 ;
+------------------------------------------------------------------------------------------------------------------------+
|                                                       QUERY 
PLAN                                                       |
+------------------------------------------------------------------------------------------------------------------------+
| HashAggregate  (cost=25.00..26.00 rows=200 width=78) (actual 
time=567.981..567.981 rows=0 loops=1)                     |
|   Filter: (count(*) > 
1)                                                                                               
|
|   ->  Seq Scan on users_sample  (cost=0.00..20.00 rows=1000 width=78) 
(actual time=0.046..160.706 rows=100489 loops=1) |
| Total runtime: 577.212 
ms                                                                                              
|
+------------------------------------------------------------------------------------------------------------------------+
(4 rows)





Tom Lane wrote:

>Rajesh Kumar Mallah <mallah@trade-india.com> writes:
>  
>
>>here is something which was the original problem
>>and is replicable.
>>    
>>
>
>Hm.  Does EXPLAIN show that the GROUP BY query is using hash
>aggregation?  Does its behavior change if you turn off enable_hashagg?
>
>			regards, tom lane
>
>  
>

view thread (9+ messages)  latest in thread

Message-ID: <40D06D1E.5000803@trade-india.com>
Permalink:  ../40D06D1E.5000803@trade-india.com/
Also on:    postgresql.org/message-id/40D06D1E.5000803@trade-india.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: mallah@trade-india.com, tgl@sss.pgh.pa.us
  Subject: Re: weired behavior... after pg_resetxlog-> dump->initdb-->reload.
  In-Reply-To: <40D06D1E.5000803@trade-india.com>
  References: <40CFFC68.5090704@trade-india.com> <21524.1087394109@sss.pgh.pa.us> <40D06096.90200@trade-india.com> <22477.1087400110@sss.pgh.pa.us> <40D06D1E.5000803@trade-india.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox