[postgis-devel] CLUSTER in 8.3

Paul Ramsey pramsey at cleverelephant.ca
Fri Dec 5 09:44:37 PST 2008


Clustering on the btree_gist instead yields the same funky result. I
am having to trouble replicating this on OS/X. Every time a winner.
Shut down the backend, bring it up, still every time a winner.
Vacuum, analyze, still winning...

P.

pramsey=# create index gid_bix on ttt using gist(gid);
CREATE INDEX
pramsey=# select count(*) from ttt;
 count
-------
  3141
(1 row)

pramsey=# cluster ttt using gid_bix;
CLUSTER
pramsey=# select count(*) from ttt;
 count
-------
     0
(1 row)



On Fri, Dec 5, 2008 at 9:34 AM, Mark Cave-Ayland
<mark.cave-ayland at siriusit.co.uk> wrote:
> Chris Hodgson wrote:
>>
>> It might be worth trying it on a non-Postgis index... if you can replicate
>> it using a the GiST B-tree implementation on a table full of integers then I
>> expect you could immediately get the attention of the Postgres devs, or at
>> least Oleg and/or Teodor.
>>
>> If you can't replicate it that way, it still doesn't rule it out as a
>> Postgresql core or GiST problem... but it certainly suggests that Postgis
>> does something differently that isn't helping.
>>
>> Chris
>
> I think the GiST part is a red herring - there is no way that a "SELECT
> COUNT(*) FROM foo" can use an index in PostgreSQL. My suspicion is that it's
> related to the use of ANALYZE/VACUUM/CLUSTER.
>
>
> ATB,
>
> Mark.
>
> --
> Mark Cave-Ayland
> Sirius Corporation - The Open Source Experts
> http://www.siriusit.co.uk
> T: +44 870 608 0063
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel
>



More information about the postgis-devel mailing list