Questions tagged «postgis-2.2»

1
为什么st_intersects比&&更快
这是一张积分表。约1M条记录 SELECT COUNT(*) as value FROM alasarr_social_mv s; Output: 976270 看起来st_intersects强制使用空间索引,但&&却没有。 采样使用ST_Intersects(282ms) SELECT COUNT(*) as value FROM alasarr_social_mv WHERE ST_Intersects( the_geom_webmercator, ST_MakeEnvelope(-410961,4920492,-402305,4926887,3857) ) Aggregate (cost=34370.18..34370.19 rows=1 width=0) (actual time=282.715..282.715 rows=1 loops=1) -> Bitmap Heap Scan on alasarr_social_mv s (cost=5572.17..34339.84 rows=60683 width=0) (actual time=21.574..240.195 rows=178010 loops=1) Recheck Cond: (the_geom_webmercator && '0103000020110F0000010000000500000000000000441519C1000000002BC5524100000000441519C1000000C069CB524100000000048E18C1000000C069CB524100000000048E18C1000000002BC5524100000000441519C1000000002BC55241'::geometry) …
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.