Karsten,

Le 19/12/2023 à 16:56, Karsten Tebling via gdal-dev a écrit :
Hello,

according to the docs (https://gdal.org/drivers/vector/gpkg.html#relationships) the geopackage driver is able to read, create, update and delete "relationships". I tried to convert some tables of a postgis database to geopackage, but there was no related tables extensions in the geopackage.

The driver supports the API to read & edit relationships, but ogr2ogr doesn't have logic to copy relationships from the source dataset to the target one, nor does the PostGIS implement the relationship API.

The related tables extension is also not listed in the supported extensions (https://gdal.org/drivers/vector/gpkg.html#level-of-support-of-geopackage-extensions).

Was missing in that section of the doc. Just added

Is it possible to convert postgis tables to a geopackage with related tables?

You'll have to use the relationship API to create them manually. Cf python testing of the GPKG driver: https://github.com/OSGeo/gdal/blob/master/autotest/ogr/ogr_gpkg.py#L6897

Even


--
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

Reply via email to