WKT of Empty Shape returns zero-length string rather than standard syntax for Empty geometry

Description

The standard SQL/MM WKT syntax for an empty geometry would be something like "POINT EMPTY" or "LINESTRING EMPTY". However, MapWinGIS returns a zero-length string for an empty geometry, which will generally be rejected by an OGR Datasource since it does not conform to the SQL/MM standard (for example, when used in the ST_GeomFromText() function).

MapWinGIS uses GDAL to format WKT, and GDAL is capable of returning a properly formatted empty WKT. The problem arises because the Shape must be converted into an OGRGeometry prior to calling GDAL, and our code does not properly convert an empty Shape into an empty OGRGeometry - instead it returns NULL.

An empty Shape should be converted into an empty OGR Geometry so that we can get a properly formatted empty WKT.

Assignee

Jerry Faust

Reporter

Jerry Faust

Labels

None

Epic Link

None

Affects versions

None

Fix versions

Priority

Medium
Configure