[postgis-users] performance of intersects(a,b)
Martin Davis
mbdavis at refractions.net
Mon Feb 18 14:41:05 PST 2008
There's some new code on the way in GEOS and PostGIS which will improve
the performance of this case. Bu it won't be anywhere near as fast as
your proposed check for an identical start point.
The "identical start point" check is great for the particular case of
comparing identical polygons. But it does nothing for the general
case. The question is: is the identical compare case common enough
that it's worth adding in this check for all cases?
Willy-Bas Loos wrote:
> Hi,
>
> I´ve noticed that intersect(a,b) is slow when i compare a (nice and
> large) geometry with itself.
> so the syntax is:
>
> select 'yes' as foo
> from table1 a, table1 b
> where a.gid=4
> and b.gid=4
> and intersects(a.the_geom, b.the_geom)
>
> This particular polygon has about 10 000 points, and the query runs
> for 4 whole seconds.
> At the first point that is being compared, however, PostGIS should
> notice that it has a "positive".
>
> I´m only using postgis 1.0, so this migt have been changed allready.
> Has it?
>
> WBL
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
--
Martin Davis
Senior Technical Architect
Refractions Research, Inc.
(250) 383-3022
More information about the postgis-users
mailing list