From: kp <pgsql@pobox.gr>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-admin@postgresql.org
Subject: Re: Sequence scans on indexed row
Date: Sun, 20 Apr 2003 17:17:43 +0200
Message-ID: <3EA2BA17.6060106@pobox.gr> (raw)
In-Reply-To: <26876.1050850718@sss.pgh.pa.us>
References: <3EA231D2.2040305@pobox.gr>
<26876.1050850718@sss.pgh.pa.us>
Tom Lane wrote:
> The only way it's wrong is if the particular value being searched for is
> much less than 1/14th of the table. IIRC Postgres 7.1 does not have
> statistics about anything beyond the most common value of the column,
> and so it's easily misled by nonuniform data distributions. If that's
> your situation then an update to 7.2.* or 7.3.* seems called for.
And this is exactly the case... This is the data distribution for the
column with the 14 distinct values:
code | record_count
----------+--------------
| 186802
aa | 432
bb | 31557
cc | 5599
dd | 15511
ee | 8364
ff | 769796
gg | 328
hh | 4911
ii | 1904
jj | 9145
kk | 576944
ll | 2296
OK. I will upgrade my installation and see what happens.
Thanks very much for the advice.
Best regards...
kp
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: pgsql@pobox.gr, tgl@sss.pgh.pa.us
Subject: Re: Sequence scans on indexed row
In-Reply-To: <3EA2BA17.6060106@pobox.gr>
References: <3EA231D2.2040305@pobox.gr> <26876.1050850718@sss.pgh.pa.us> <3EA2BA17.6060106@pobox.gr>
* 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