[postgis-users] GeomUnion and Intersection

strk at refractions.net strk at refractions.net
Tue Mar 1 06:01:56 PST 2005


This should give you the simplified coastline:

SELECT AsGML(simplify(geomunion(the_geom), .05)) FROM worldmap;

--strk;

On Tue, Mar 01, 2005 at 02:56:32PM +0100, roxana at torre.nl wrote:
> Hello,
> I'm getting something further with my worldmap database. I have the esri
> shapefile of Europe in it, now I'm trying to get data and visualize it. I'm
> using the gml output, and that's going fine. 
> The idea is to get all borders and coastlines, I want to have as less as
> possible points. The queries I'm using are like this:
> 
> for the coastlines:
> 
> SELECT AsGML(simplify(GeomUnion((SELECT the_geom FROM worldmap WHERE cntry_name
> ='France'),GeomUnion((SELECT the_geom FROM worldmap WHERE cntry_name
> ='Netherlands'),(SELECT the_geom FROM worldmap WHERE cntry_name
> ='Belgium'))),0.05));
> 
> and for each pair of countries:
> 
> SELECT AsGML(simplify(Intersection((SELECT the_geom FROM worldmap WHERE
> cntry_name ='France'),(SELECT the_geom FROM worldmap WHERE cntry_name
> ='Belgium')),0.05));
> 
> Is there another way to do this?. Specially for the first query: i saw you can
> also use it with "geometry set" but I couldn't find what that is.
> 
> Thanks,
> roxana
> 
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
> 
> _______________________________________________
> 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