SQL/MMore Acrobatics
SELECT b.gid AS gid,
ST_Closestpoint(ST_Collect(a.the_geom), b.the_geom) AS the_geom,
b.stream_nam
FROM public.hydro_polyline_merge1 a INNER JOIN base.streams_phwh b
ON ST_Dwithin(a.the_geom, b.the_geom, 1000)
GROUP BY b.gid, b.the_geom, b.stream_nam Continue reading SQL/MMore Acrobatics