pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: AndyG <andy.gumbrecht@orprovision.com>
To: pgsql-performance@postgresql.org
Subject: Re: Slow query, where am I going wrong?
Date: Wed, 31 Oct 2012 02:18:23 -0700 (PDT)
Message-ID: <1351675103112-5730140.post@n5.nabble.com> (raw)
In-Reply-To: <D960CB61B694CF459DCFB4B0128514C2089A62C4@exadv11.host.magwien.gv.at>
References: <508F82E1.3020202@orprovision.com>
	<D960CB61B694CF459DCFB4B0128514C2089A60C2@exadv11.host.magwien.gv.at>
	<1351608872327-5730059.post@n5.nabble.com>
	<D960CB61B694CF459DCFB4B0128514C2089A62C4@exadv11.host.magwien.gv.at>

Albe Laurenz *EXTERN* wrote
> Increasing the statistics for test_result.id_recipe_version
> had no effect?
> 
>> I am going to normalize the table some more before partitioning.
> 
> How do you think that partitioning will help?

I increased the statistics in steps up to 5000 (with vacuum analyse) - Seems
to be as good as it gets.

http://explain.depesz.com/s/z2a

The simulated data is about a months worth. Partitioning is only really
expected to help on insert, but that's pretty critical for us.

At the moment test_item contains way too much repeated data IMHO, and I will
address that asap (is going to hurt ).

I will also look into creating an aggregate table to hold the 'distinct'
values.

Andy.





--
View this message in context: http://postgresql.1045698.n5.nabble.com/Slow-query-where-am-I-going-wrong-tp5730015p5730140.html
Sent from the PostgreSQL - performance mailing list archive at Nabble.com.




view thread (11+ messages)  latest in thread

Message-ID: <1351675103112-5730140.post@n5.nabble.com>
Permalink:  ../1351675103112-5730140.post@n5.nabble.com/
Also on:    postgresql.org/message-id/1351675103112-5730140.post@n5.nabble.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: andy.gumbrecht@orprovision.com
  Subject: Re: Slow query, where am I going wrong?
  In-Reply-To: <1351675103112-5730140.post@n5.nabble.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