pg.ddx.io pgsql-performance@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Chris Cheston <ccheston@gmail.com>
To: Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Cc: pgsql-performance@postgresql.org
Subject: Re: postgres 7.4 at 100%
Date: Wed, 30 Jun 2004 00:34:52 -0700
Message-ID: <e071108e040630003475e9ac81@mail.gmail.com> (raw )
In-Reply-To: <40E26C2C.9080601@familyhealth.com.au >
References: <e071108e04062423591d2b8aa9@mail.gmail.com >
<1088397641.1105.10.camel@localhost >
<17884.1088399982@sss.pgh.pa.us >
<200406280947.59420.josh@agliodbs.com >
<e071108e0406290100338c171d@mail.gmail.com >
<40E1266D.3040607@familyhealth.com.au >
<e071108e04062901377f6591c9@mail.gmail.com >
<40E192CC.90707@ehpg.net >
<e071108e040630001973bb802e@mail.gmail.com >
<40E26C2C.9080601@familyhealth.com.au >
I see - thanks very much. I created an index for column 'oid' which I
was using in a WHERE. So rule of thumb- create an index for column(s)
which I use in WHERE queries.
Thanks,
Chis
On Wed, 30 Jun 2004 15:30:52 +0800, Christopher Kings-Lynne
<chriskl@familyhealth.com.au> wrote:
>
>
> > Why would I or would I not create multiple indexes in a table? I
> > created another index in the same table an it's improved performance
> > even more.
>
> You create indexes when you need indexes. Indexes are most helpful when
> they match the WHERE clause of your selects.
>
> So, if you commonly do one query that selects on one column, and another
> query that selects on two other columns - then create one index on the
> first column and another index over the second two columns.
>
> Chris
>
view thread (24+ messages) latest in thread
Message-ID: <e071108e040630003475e9ac81@mail.gmail.com>
Permalink: ../e071108e040630003475e9ac81@mail.gmail.com/
Also on: postgresql.org/message-id/e071108e040630003475e9ac81@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: ccheston@gmail.com, chriskl@familyhealth.com.au
Subject: Re: postgres 7.4 at 100%
In-Reply-To: <e071108e040630003475e9ac81@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