From: Tom Lane <tgl@sss.pgh.pa.us>
To: Josh Berkus <josh@agliodbs.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: View performance question
Date: Fri, 22 Jun 2001 17:11:31 -0400
Message-ID: <5809.993244291@sss.pgh.pa.us> (raw)
In-Reply-To: <web-76095@davinci.ethosmedia.com>
References: <web-76095@davinci.ethosmedia.com>
"Josh Berkus" <josh@agliodbs.com> writes:
> I tried re-arranging the JOINS as you suggested. There was no impact on
> gross performance (still 42 seconds to return the first row). And yes,
> it is the classic "star" database.
> What follows is the query plan.
Hm. The query plan looks very reasonable: hashing the smaller tables is
exactly what I'd think it should do. If the rows estimates shown in the
plan are accurate, it's hard to see how it's spending 42 seconds on
this.
The primary tables seem to be big enough that they are probably being
divided into hash batches, if you use the default sort_mem setting of
512K. Try increasing sort_mem (SET SORT_MEM TO 5000 or so) and see if
that makes a difference.
regards, tom lane
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-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, josh@agliodbs.com
Subject: Re: View performance question
In-Reply-To: <5809.993244291@sss.pgh.pa.us>
* 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