cdb_union_adgacent

This commit is contained in:
Stuart Lynn
2016-02-24 13:51:18 -05:00
parent abfda1c75e
commit e84b467cbc
4 changed files with 65 additions and 0 deletions
@@ -0,0 +1,9 @@
\i test/fixtures/touching_polygons.sql
WITH joined_polygons AS (
SELECT cdb_union_adjacent(the_geom) the_geom FROM touching_polygons
),
unnested_polygons as (
select unnest(joined_polygons.the_geom) the_geom from joined_polygons
)
select ST_ASTEXT(unnested_polygons.the_geom) from unnested_polygons;