[gdal-dev] Deleting raster layers from geopackages
Even Rouault
even.rouault at spatialys.com
Wed Oct 3 11:56:53 PDT 2018
On mercredi 3 octobre 2018 11:22:12 CEST andreaerdna wrote:
> Hi,
> from what I've read in bug report #7013 [1] and in the message of the commit
> fixing it [2], I thought the problem of deleting a raster layer, including
> all of its references in other tables, from a geopackage had been solved.
> I've also read previous thread on this list [3] [4] that left me a little
> confused.
>
> However, I tried to delete a raster layer name test_dtm from test.gpkg using
> (with GDAL 2.3.1 and 2.4.0dev from gisinternal):
As you discovered with your PR, support for deleting gridded coverage raster
table (the ones created for non byte data) vs regular 'tiles' raster table was
indeed missing.
>
> ogrinfo -sql "DROP TABLE test_dtm" test.gpkg
>
> but it only deleted the test_dtm table without also deleting the
> corresponding records in gpkg_contents, gpkg_tile_matrix, gpkg_extensions,
> etc.
>
> There is probably something that I did not quite understand in this regard.
GDALGeoPackageDataset::DeleteVectorOrRasterLayer() should be extented to look
for '2d-gridded-coverage' in the test that detects if it is a raster or vector
layer.
Even
--
Spatialys - Geospatial professional services
http://www.spatialys.com
More information about the gdal-dev
mailing list