[postgis-users] Efficiency of <->, # and &&/st_distance
Jan Hartmann
j.l.h.hartmann at uva.nl
Mon Feb 6 06:25:44 PST 2012
Hi,
I am working on an interactive application to add and remove points from
a map. When removing, the user clicks on the map and should get back the
nearest point in the database. Normally, I would do this with something
like: "select ... where <point> && the_geom and
st_distance(<point>,the_geom) < 10)". I see there are two new operators
now: # and <->. Is there any difference in efficiency in this case?
Also: all three methods require a GIST index. However, this is a very
interactive application that continuously changes the number of points.
The number of points can potentially grow quite large (hundreds of
thousands) Are there any rules to organise the database so as to
optimize GIST access and update (e.g. maximum number of records,
partitioning into multiple tables)?
Jan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120206/a2de7c05/attachment.html>
More information about the postgis-users
mailing list