[postgis-devel] GeomUnion Performance Info

strk at refractions.net strk at refractions.net
Thu Jun 23 02:51:53 PDT 2005


On Wed, Jun 22, 2005 at 08:30:22PM -0400, Bill Binko wrote:
> On Thu, 23 Jun 2005 strk at refractions.net wrote:
> 
> > Similar in terms of performances also or just visual effect ?
> > Did you try the short-circuit tests ? Would you add curves
> > for them as well if you do ?
> > 
> 
> The performance in in the graph as "Spatial Index".  I thought that's what 
> ORDER BY was using when I did the graphs.  It is similar to, but slower 
> than, the clustered GiST.

Try always using ORDER BY so scan overhead is about the same.
Add two integer columns to your table, fill one with GiST ordering
and the other with BTREE ordering, define indexes for both.
Then use ORDER BY both.

> I suppose I can cluster on the attribute I just added which would give a 
> clustered btree number.  I can add that to the list if you think it's 
> worth it.

I think it is worth comparing GiST and btree so making overhead
comparable seems a good idea (either clustering or ordering by both
types)

> I have not doing the short-circuit yet, as I will need to upgrade PostGIS 
> from 1.1rc6 to CVS HEAD which may be painful.  (I just don't want daytime 
> downtime on it.)

You don't need to upgrade postgis (from 1.0.0rc6) in order to use
short-circuits (as long as you already built it against geos-2.x).

--strk;



More information about the postgis-devel mailing list