pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Csaba Nagy <nagy@ecircle-ag.com>
To: Simon Riggs <simon@2ndquadrant.com>
Cc: postgres performance list <pgsql-performance@postgresql.org>
Subject: Re: Searching for the cause of a bad plan
Date: Fri, 21 Sep 2007 17:48:09 +0200
Message-ID: <1190389689.4661.220.camel@PCD12478> (raw)
In-Reply-To: <1190384799.4661.217.camel@PCD12478>
References: <1190369024.4661.173.camel@PCD12478>
	<1190372365.4202.14.camel@ebony.site>
	<1190374166.4661.194.camel@PCD12478>
	<1190374478.4202.20.camel@ebony.site>
	<1190376744.4661.208.camel@PCD12478>
	<1190381777.4202.50.camel@ebony.site>
	<1190384799.4661.217.camel@PCD12478>

> OK, I can confirm that. I set the statistics target for column "a" on
> table_a to 1000, analyzed, and got the plan below. The only downside is
> that analyze became quite expensive on table_a, it took 15 minutes and
> touched half of the pages... I will experiment with lower settings,
> maybe it will work with less than 1000 too.

So, just to finish this up: setting statistics to 100 worked too, and it
has an acceptable impact on analyze. My original (more complicated)
query is working fine now, with visible effects on server load...

Thanks Simon for your help !

Cheers,
Csaba.





view thread (26+ messages)  latest in thread

Message-ID: <1190389689.4661.220.camel@PCD12478>
Permalink:  ../1190389689.4661.220.camel@PCD12478/
Also on:    postgresql.org/message-id/1190389689.4661.220.camel@PCD12478

 · 

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: nagy@ecircle-ag.com, simon@2ndquadrant.com
  Subject: Re: Searching for the cause of a bad plan
  In-Reply-To: <1190389689.4661.220.camel@PCD12478>

* 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