[gdal-dev] Official support for empty field names in OGR?

Even Rouault even.rouault at spatialys.com
Sun Sep 13 04:37:47 PDT 2020


On samedi 12 septembre 2020 19:48:58 CEST Alan Snow wrote:
> This is a question originating from:
> https://github.com/Toblerity/Fiona/pull/955
> 
> It seems that empty field names work in GDAL/OGR without issue across the
> drivers I have tested (ESRI Shapefile, GeoJSON, GPKG, CSV). However, one
> question Sean Gillies and I have is: Is this behavior expected and
> supported?

An empty string is just a string, so unless drivers actively test for it,  that should work I guess. 
But this is certainly playing a bit with fire. Wouldn't be surprised that applications consuming 
such empty field name don't like it much.

Actually just seeing that PostgreSQL and mySQL don't like empty string as a column. It seems 
to be a general SQL92 restriction actually (SQLite3 is an exception to that)

Even


-- 
Spatialys - Geospatial professional services
http://www.spatialys.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20200913/27f7a355/attachment.html>


More information about the gdal-dev mailing list