[postgis-users] Call for Semantics (ST_CollectionTypes())

Mark Cave-Ayland mark.cave-ayland at siriusit.co.uk
Wed Jan 28 16:40:09 PST 2009

Paul Ramsey wrote:

> I would like to add a function that takes an anonymous
> GEOMETRYCOLLECTION and returns something more structured:
> - a GEOMETRYCOLLECTION where the first element is a MULTLIPOLYGON, the
> second a MULTILINESTRING and the third a MULTIPOINT?
> - a tuple, with elements 'polygons', 'linestrings', 'points', each
> with one multi* of each?
> - a tuple, with elements 'polygons', 'linestrings', 'point', each with
> an array of singletons?
> The key here is to provide a useful flat structure to pull info out
> of. Some information in the GEOMETRYCOLLECTION *will be lost*, (but
> that seems an acceptable price)
> Another approach, which might be simpler for users to grok would be:
> ST_CollectionAsMultiPolygon() returns just the polygon elements of a collection.
> ... etc ...
> Thoughts?
> P.

Hi Paul,

I'm still struggling to get an idea of exactly what these proposed 
functions are trying to achieve. Can you show some potential 
problems/SQL statements showing how you would envisage these functions 
being used?



Mark Cave-Ayland
Sirius Corporation - The Open Source Experts
T: +44 870 608 0063

More information about the postgis-users mailing list