Hi,
http://www.geopackage.org/spec/#_sqlite_container "Table 1. GeoPackage
Data Types" is pretty clear on which data types are valid in a
GeoPackage vector table, and INT4, VARCHAR(...) or FLOAT8 are not.
You can also use the
https://github.com/OSGeo/gdal/blob/master/swig/python/gdal-utils/osgeo_utils/samples/validate_gpkg.py
script although it is not official, but hopefully should be faithful to
the spec. Otherwise you can use the official validator at
https://cite.opengeospatial.org/teamengine/
Even
Le 14/02/2024 à 14:51, Raymond Nijssen via gdal-dev a écrit :
Some fields in geopackages generated by GeoServer are not supported by
GDAL. I have already made a ticket for GeoServer, but I'm unsure where
the problem lies.
More info in the GeoServer ticket here:
https://osgeo-org.atlassian.net/browse/GEOS-11292
---
Gpkg output can contain fields of type INT4, VARCHAR(255) and FLOAT8
which are not supported by GDAL/OGR. For this reason, QGIS, GRASS and
FME ignore those fields on import.
ray@fw13:~/Downloads$ ogrinfo ext_nat_nbp.gpkg
Warning 1: GPKG: unrecognized user_version=0x00000000 (0) on
'ext_nat_nbp.gpkg'
INFO: Open of ext_nat_nbp.gpkg' using driver GPKG' successful.
Warning 1: Field format 'INT4' not supported. Interpreted as INT
Warning 1: Field format 'VARCHAR(255)' not supported
Warning 1: geometry column 'deelgebied' of type 'VARCHAR(255)' ignored
Warning 1: Field format 'FLOAT8' not supported
Warning 1: geometry column 'oppervlakte_hectare' of type 'FLOAT8' ignored
Warning 1: Field format 'VARCHAR(255)' not supported
Warning 1: geometry column 'plan_naam' of type 'VARCHAR(255)' ignored
1: ext_nat_nbp (Multi Polygon)
The INT4 fields are visible as INT, but all other other fields are
ignored. (There’s also an “unrecognized user version“.)
---
This also affects QGIS, GRASS and FME, cause they use GDAL for opening
the data source.
Who's right and who's wrong here? :)
Kind regards,
Raymond
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev
--
http://www.spatialys.com
My software is free, but my time generally not.
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev