pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Yeb Havinga <yebhavinga@gmail.com>
To: JOUANIN Nicolas (44) <nicolas.jouanin@dgfip.finances.gouv.fr>
Cc: pgsql-performance@postgresql.org
Subject: Re: Two different execution plan for the same request
Date: Wed, 07 Jul 2010 10:59:23 +0200
Message-ID: <4C3441EB.8010405@gmail.com> (raw)
In-Reply-To: <4C343F31.2050402@dgfip.finances.gouv.fr>
References: <4C3432F0.1090004@dgfip.finances.gouv.fr>
	<4C343A59.7050908@gmail.com>
	<4C343F31.2050402@dgfip.finances.gouv.fr>

JOUANIN Nicolas (44) wrote:
>
> The strange thing is that this morning explain analyze now gives a 
> much better duration :
>
> There were no modification made on the database except a restart 
> yesterday evening and a vacuumdb --analyse ran at night.
If the earlier bad query was run on a fresh imported database that was 
not ANALYZEd, it would explain the different and likely bad plan. If you 
want to know for sure this is the cause, instead of e.g. faulty 
hardware, you could verify redoing the import + query without analyze.

regards,
Yeb Havinga




view thread (7+ messages)  latest in thread

Message-ID: <4C3441EB.8010405@gmail.com>
Permalink:  ../4C3441EB.8010405@gmail.com/
Also on:    postgresql.org/message-id/4C3441EB.8010405@gmail.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 using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: yebhavinga@gmail.com, nicolas.jouanin@dgfip.finances.gouv.fr
  Subject: Re: Two different execution plan for the same request
  In-Reply-To: <4C3441EB.8010405@gmail.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