Open DIANGHONG opened 3 years ago
select t.num,t.city,t.wgs84_lng,t.wgs84_lat, TRUNCATE(st_distance_sphere(point (113.8064049, 22.7300434),point(t.wgs84_lng,t.wgs84_lat)),2) as distance from moran_point t where t.city = '深圳' HAVING distance > 0 and distance < 3500 ORDER BY distance;
不能,直接手写效果更好。
谢谢解答!
select t.num,t.city,t.wgs84_lng,t.wgs84_lat, TRUNCATE(st_distance_sphere(point (113.8064049, 22.7300434),point(t.wgs84_lng,t.wgs84_lat)),2) as distance from moran_point t where t.city = '深圳' HAVING distance > 0 and distance < 3500 ORDER BY distance;