[geos-devel] MakeValid and empty collection component

Sandro Santilli strk at kbt.io
Thu Dec 10 03:16:40 PST 2020


On Thu, Dec 10, 2020 at 12:08:58PM +0100, Sandro Santilli wrote:

> Odd, for a MULTIPOINT with empty components it seems to strip it.
> But I cannot add the test because it looks like EMPTY is not accepted
> in WKT:
> 
>     MULTIPOINT(EMPTY,1 1,EMPTY,0 0)
>     ParseException: Expected number but encountered word: 'EMPTY')

Ok, figured: it's just the PostGIS->GEOS->PostGIS roundtrip conversion
dropping those components !

  strk=# select ST_AsText(postgis_geos_noop('GEOMETRYCOLLECTION(POINT EMPTY, POINT(1 1))'));
             st_astext
  --------------------------------
   GEOMETRYCOLLECTION(POINT(1 1))
  (1 row)

So, not related to GEOSMakeValid per-se, just with the adapter...

--strk;


More information about the geos-devel mailing list