[postgis-users] Merge function in PostGIS
Paul Ramsey
pramsey at refractions.net
Mon Oct 30 17:49:21 PST 2006
Or, possibly:
select buffer(the_geom,0.01) from tablename where geometrytype =
'MULTIPOLYGON';
On 30-Oct-06, at 5:34 PM, Michael Fuhr wrote:
> On Mon, Oct 30, 2006 at 01:50:26PM -0700, Bruce Rindahl wrote:
>> I need a merge function in PostGIS. What this means is if I have a
>> multipolygon and if any two parts share a common edge I need the
>> union of
>> the two parts in one polygon. For example if I have:
>> MULTIPOLYGON(((partA)),((partB)),((partC))) where partA and partC
>> intersect
>> or share a common edge, the result will be:
>> MULTIPOLYGON(((Union of partA & partC)),((partB)))
>
> Something like this might work:
>
> SELECT GeomUnion(geom)
> FROM (SELECT (dump(the_geom)).geom
> FROM tablename
> WHERE ...) AS s;
>
> --
> Michael Fuhr
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
More information about the postgis-users
mailing list