Re: Possible to improve query plan?

From: Jayadevan M <Jayadevan(dot)Maymala(at)ibsplc(dot)com>
To: Jeremy Palmer <JPalmer(at)linz(dot)govt(dot)nz>
Cc: "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>, pgsql-performance-owner(at)postgresql(dot)org
Subject: Re: Possible to improve query plan?
Date: 2011-01-17 08:44:05
Message-ID: OFCF071F4A.48152E2C-ON6525781B.002EEEE4-6525781B.002FFBBE@ibsplc.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Hello,

>
> The distribution of the data is that all but 120,000 rows have null
> values in the _revision_expired column.
>

A shot in the dark - will a partial index on the above column help?
http://www.postgresql.org/docs/current/interactive/indexes-partial.html
http://en.wikipedia.org/wiki/Partial_index

One link with discussion about it...
http://www.devheads.net/database/postgresql/general/when-can-postgresql-use-partial-not-null-index-seems-depend-size-clause-even-enable-seqscan.htm

Regards,
Jayadevan

DISCLAIMER:

"The information in this e-mail and any attachment is intended only for
the person to whom it is addressed and may contain confidential and/or
privileged material. If you have received this e-mail in error, kindly
contact the sender and destroy all copies of the original communication.
IBS makes no warranty, express or implied, nor guarantees the accuracy,
adequacy or completeness of the information contained in this email or any
attachment and is not liable for any errors, defects, omissions, viruses
or for resultant loss or damage, if any, direct or indirect."

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Ing. Marcos Ortiz Valmaseda 2011-01-17 13:37:35 Re: Possible to improve query plan?
Previous Message Zotov 2011-01-17 08:03:29 Bad plan when join on function