From: | Matteo Beccati <php(at)beccati(dot)com> |
---|---|
To: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Does EXPLAIN ANALYZE show a wrong plan for MIN/MAX? |
Date: | 2005-11-11 11:48:15 |
Message-ID: | 437484FF.1080809@beccati.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Martijn van Oosterhout wrote:
>> I've noticed that sometimes EXPLAIN ANALYZE is much slower than the
>> plain query. After investigating I found that it happens when using MIN
>> or MAX aggregates.
>>
>> It seems that the plan outputted is not the optimized one (available
>> since 8.1) that is really used when running the plain query.
>
> It may also be that the overhead of calling gettimeofday() several
> times per tuple is blowing the time out. What platform is this?
FreeBSD 5.4-RELEASE on an HP DL380 G4.
I've also tried to do the same on another machine which has 8.0.3 and
FreeBSD 4.9-RELEASE-p3: times for the same query are 15s vs 63s with
EXPLAIN ANALYZE. Of course I know 8.0 doesn't optimize min/max the same
way 8.1 does.
Hope this helps.
Best regards
--
Matteo Beccati
http://phpadsnew.com
http://phppgads.com
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2005-11-11 12:18:31 | Re: lc_numeric and decimal delimiter |
Previous Message | Martijn van Oosterhout | 2005-11-11 11:21:28 | Re: Does EXPLAIN ANALYZE show a wrong plan for MIN/MAX? |