pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Query is sometimes fast and sometimes slow: what could be the reason?
2+ messages / 2 participants
[nested] [flat]

* Query is sometimes fast and sometimes slow: what could be the reason?
@ 2022-09-14 15:02  tiaswin@gmx.de
  0 siblings, 1 reply; 2+ messages in thread

From: tiaswin@gmx.de @ 2022-09-14 15:02 UTC (permalink / raw)
  To: pgsql-performance@lists.postgresql.org

<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>What could be the reason of a query, which is sometimes fast and sometimes slow (factor &gt;10x)?</div>

<div>(running on a large table).</div>

<div>&nbsp;</div>

<div>&nbsp;</div></div></body></html>





^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Query is sometimes fast and sometimes slow: what could be the reason?
@ 2022-09-14 15:59  Justin Pryzby <pryzby@telsasoft.com>
  parent: tiaswin@gmx.de
  0 siblings, 0 replies; 2+ messages in thread

From: Justin Pryzby @ 2022-09-14 15:59 UTC (permalink / raw)
  To: tiaswin@gmx.de; +Cc: pgsql-performance@lists.postgresql.org

On Wed, Sep 14, 2022 at 05:02:07PM +0200, tiaswin@gmx.de wrote:
> <html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>What could be the reason of a query, which is sometimes fast and sometimes slow (factor &gt;10x)?</div>
> <div>(running on a large table).</div>
> <div>&nbsp;</div>
> <div>&nbsp;</div></div></body></html>

Lots of possible issues.  Is it using a different query plan ?
Collect a good plan and a bad one and compare, or send both.
Perhaps use autoexplain to do so.

Turn on logging and send as much information as you can as described
here.
https://wiki.postgresql.org/wiki/Slow_Query_Questions

Please try to configure your mail client to send text mail (instead of
or in addition to the html one).

-- 
Justin





^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2022-09-14 15:59 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2022-09-14 15:02 Query is sometimes fast and sometimes slow: what could be the reason? tiaswin@gmx.de
2022-09-14 15:59 ` Justin Pryzby <pryzby@telsasoft.com>

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