[QGIS-Developer] PyQGIS : Creating a Geopackage layer without adding features

René-Luc Dhont rldhont at gmail.com
Thu May 23 00:27:38 PDT 2019


Hi Dev,

I would like to create a geopackage with multiple layers but without 
features. I'd like to do the same thing as the 
QgsNewGeoPackageLayerDialog do but without user interface in python.

I have tested with QgsVectorFileWriter, but the file and layer are not 
created if add feature is not used.

Do I have to use Python OGR packaging to do so ?

Regards,
René-Luc


More information about the QGIS-Developer mailing list