Re: Sequence scans on indexed row - Mailing list pgsql-admin

From kp
Subject Re: Sequence scans on indexed row
Date
Msg-id 3EA2BA17.6060106@pobox.gr
Whole thread Raw
In response to Re: Sequence scans on indexed row  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-admin
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


pgsql-admin by date:

Previous
From: Tom Lane
Date:
Subject: Re: Sequence scans on indexed row
Next
From: Pedro Salazar
Date:
Subject: restore database with schema: owner schema must have superuser privileges?