[postgis-tickets] [PostGIS] #3470: ST_Polygonize doesn't accept NULL geometries
PostGIS
trac at osgeo.org
Thu Feb 25 02:33:35 PST 2016
#3470: ST_Polygonize doesn't accept NULL geometries
---------------------------------------+---------------------
Reporter: kohnivo | Owner: pramsey
Type: defect | Status: new
Priority: low | Milestone:
Component: postgis | Version: 2.2.x
Keywords: ST_Polygonize, NULL value |
---------------------------------------+---------------------
Postgis 2.2.1 running on Win (PG 9.4.5 64bit, spec with
postgis_full_version():
{{{
"POSTGIS="2.2.1 r14555" GEOS="3.5.0-CAPI-1.9.0 r4090" SFCGAL="1.2.2"
PROJ="Rel. 4.9.1, 04 March 2015" GDAL="GDAL 2.0.1, released 2015/09/15"
LIBXML="2.7.8" LIBJSON="0.12" TOPOLOGY RASTER"
}}}
) throws an error if trying to do ST_Polygonize on NULL geometries:
{{{
ERROR: getPoint4d_p: point offset out of range
SQL state: XX000
}}}
Test code (either linestring or multilinestring):
{{{
WITH w AS (SELECT NULL::geometry(MULTILINESTRING,5514) as geom)
SELECT ST_Polygonize(geom)
FROM w
}}}
Postgis 2.1.1 running on Win (PG 9.3 64bit) and Ubuntu (PG 9.4 64bit)
throws this:
{{{
ERROR: Exception in LWGEOM2GEOS: curved geometry not supported.
SQL state: XX000
}}}
Maybe it is not a bug but it confused me quite a lot and took me some time
to find out what is going on, because I didn't know that there are some
NULLs in the dataset. For some reason I would expect returned NULL same as
eg. ST_Envelope or ST_BuildArea does.
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/3470>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list