pg.ddx.io pgsql-performance@postgresql.org mailing list archive
help / color / mirror / Atom feed From: David Wilson <david.t.wilson@gmail.com>
To: Віталій Тимчишин <tivv00@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: PostgreSQL OR performance
Date: Fri, 7 Nov 2008 05:07:32 -0500
Message-ID: <e7f9235d0811070207ka8baab0w5ffe6cfbb947b56b@mail.gmail.com> (raw )
In-Reply-To: <331e40660811070114rd70cf0dy194020a9f9ea8802@mail.gmail.com >
References: <331e40660811050312u552cab53ifa88e493e1c4f7ac@mail.gmail.com >
<1225902700.1432.53.camel@jdavis >
<331e40660811060246m51df553egd4e2ba91f08d1434@mail.gmail.com >
<29e3942f0811060426k5fe34b1av401a2dba62e4ae3c@mail.gmail.com >
<331e40660811060833l49bf837em41ca88d4b2061ea1@mail.gmail.com >
<49131ED5.80307@archonet.com >
<331e40660811060937q460e6f9fvf336455200d31f56@mail.gmail.com >
<331e40660811070114rd70cf0dy194020a9f9ea8802@mail.gmail.com >
On Fri, Nov 7, 2008 at 4:14 AM, Віталій Тимчишин <tivv00@gmail.com> wrote:
> "Merge Join (cost=518771.07..62884559.80 rows=1386158171 width=32) (actual
> time=30292.802..755751.242 rows=34749 loops=1)"
Have you tried increasing the default_statistics_target? The planner
is expecting 1.3 billion rows to be produced from a query that's only
actually producting 35k, which probably indicates some very bad
statistics. At the same time, the materialize step produces 242
million rows when the planner only expects to produce 2.3, indicating
a similar problem in the opposite direction. This probably means that
the planner is choosing plans that would be optimal if it was making
good guesses but are decidedly sub-optimal for your actual data.
--
- David T. Wilson
david.t.wilson@gmail.com
view thread (16+ messages) latest in thread
Message-ID: <e7f9235d0811070207ka8baab0w5ffe6cfbb947b56b@mail.gmail.com>
Permalink: ../e7f9235d0811070207ka8baab0w5ffe6cfbb947b56b@mail.gmail.com/
Also on: postgresql.org/message-id/e7f9235d0811070207ka8baab0w5ffe6cfbb947b56b@mail.gmail.com
copy link · copy postgr.es
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: david.t.wilson@gmail.com, tivv00@gmail.com
Subject: Re: PostgreSQL OR performance
In-Reply-To: <e7f9235d0811070207ka8baab0w5ffe6cfbb947b56b@mail.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