Answer the question
In order to leave comments, you need to log in
How can I find out which polygon a point is in?
How to find which polygon a point is in?
I have polygons of regions of the Russian Federation stored in the polygons table. There are 8 of them, a large increase in their number is planned. Structure:
region_id (int), lat (decimal, 8, 6), lng (decimal, 9, 6).
region_id - ID of the region
lat - latitude of the point
lng - longitude of the point
How to find which polygon a point belongs to? How to optimize a query for loads? I need to know only the region_id of the polygon.
Google gives only information on how to check that the point is in the region.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question