ср, 30 нояб. 2022 г., 20:51 Brad White <b55white@xxxxxxxxx>:
On 11/30/2022 9:48 AM, Вадим Самохин wrote:
> Thank you so much Ivan, it worked!
Can you give any more detail on which approach you took, for the sake of
future followers?
Sure, I multiplied all points' coordinates by a factor of 10^6.
Here are the steps to demonstrate that the solution Ivan gave worked:
1. create table zones (
zone_id int,
zone_polygon polygon,
description text
);
zone_id int,
zone_polygon polygon,
description text
);
create index zones__zone_polygon on zones using gist(zone_polygon poly_ops);
2. insert into zones (zone_polygon) values ('(37622012.9,55751936.7),(37621534.4,55753661.6),(37617206.4,55755950.9),(37622012.9,55751936.7)');
3. select count(1) from zones where zone_polygon @> '(37617635,55755814)'::polygon;
count
-------
0
(1 row)
count
-------
0
(1 row)