Re: Please help to improve SELECT JOIN performance, EXPLAIN ANALYZE attached

From: "Peter J(dot) Holzer" <hjp-pgsql(at)hjp(dot)at>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Please help to improve SELECT JOIN performance, EXPLAIN ANALYZE attached
Date: 2021-02-20 13:56:41
Message-ID: 20210220135641.GB30604@hjp.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 2021-02-20 06:43:28 -0700, Michael Lewis wrote:
> Using auto_explain may be needed to catch the plan when it is slow, if the
> other suggestions don't resolve things for you.

Yes, auto_explain is very helpful. Unfortunately, by default it only
does an explain, not the equivalent of an explain analyze. So you know
what the plan was and what the total time was, but you still don't know
where it spent that time.

You can set auto_explain.log_analyze = on, but the documentation warns
that "this can have an extremely negative impact on performance". Does
anybody have experience with trying this in a real-world workload? (I
was never brave enough)

hp

--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | hjp(at)hjp(dot)at | -- Charles Stross, "Creative writing
__/ | http://www.hjp.at/ | challenge!"

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Alexander Farber 2021-02-20 15:15:55 Re: Please help to improve SELECT JOIN performance, EXPLAIN ANALYZE attached
Previous Message Michael Lewis 2021-02-20 13:43:28 Re: Please help to improve SELECT JOIN performance, EXPLAIN ANALYZE attached