Skip to main content
7 events
when toggle format what by license comment
Aug 11, 2016 at 13:53 comment added Sharky for the record i went with geometry(geometry, 4326) as advised in your comment thanks!
Aug 11, 2016 at 12:12 vote accept Sharky
Apr 18, 2016 at 23:56 comment added user30184 You are right that a mixture of different geometries can only be stored as GeometryCollection. However, GeometryCollection doesn not need to be a mixture, this is also valid GEOMETRYCOLLECTION ( POINT ( -40 20 )).
Apr 18, 2016 at 23:48 comment added user30184 So you mean "a database which must be able to store (multi)points, (multi)linestrings and (multi)polygons.for each feature? In that case the both GeometryCollection and three separate geometries are good in theory.
Apr 18, 2016 at 10:32 comment added Regina Obe You want your column to be geometry(geometry, 4326) . The geometry subtype type is a catchall for any 2d geometry (including multies and geometry collection). GeometryCollection only supports things like GEOMETRYCOLLECTION. Yes the record with mix of multipoints etc. would be a geometry collection - but probably looks like GEOMETRYCOLLECT(MULTIPOINT(..), MULTIPOLYGON(..)).
Apr 18, 2016 at 6:54 comment added Sharky i'll go back to the docs for a re-read but please help me straight this out. my column on database is of type geometry(GeometryCollection,4326), and one record there contains a mix of (multi)points,(multi)linestrings and (multi)polygons. Isn't that a geometry collection? If not what it is? Multipoints is not a geometry collection, but a mixture of multipoints and multilinestrings is a geometry collection? Am i correct?
Apr 18, 2016 at 6:43 history answered Regina Obe CC BY-SA 3.0