[postgis-users] What's the Fastest way to find if Polygons cover an input point?
Devdatta Tengshe
devdatta at tengshe.in
Tue Jul 3 03:50:08 PDT 2018
Hi all,
I'm developing an API which will help us figure out if we can server a
potential customer. For this, I have a PostGIS Table with polygon
representing the service area of each of our store. There could be up to
10,000 polygons in the table. These polygons are geometries in EPSG:4326
and has a Gist Index.
Currently I'm using the following query to figure out if we can potentially
service the customer:
Select count(id) from service_areas where
ST_CoveredBy(ST_SetSRID(ST_MakePoint(78.46239,17.30360),4326), geom);
Is there a faster way to get if any of the polygons cover my input Point?
Regards,
Devdatta
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20180703/db960ed4/attachment.html>
More information about the postgis-users
mailing list