Re: [Qgis-user] Open geometryless tables from GeoPackage
Le jeudi 28 avril 2016 07:03:45, Stefan Ziegler a écrit : > Yes, compiled and running against gdal master. > > Do you just drag 'n' drop the geopackage file into QGIS? Do you mind trying > this one: http://sogeo.services/tmp/av_2495.gpkg > > I checked it with "ogrinfo -so av_2495.gpkg" and it only shows the tables > with geometry (gdal 1.11 and gdal master). Stefan, OK, I see. This database hasn't been produced by GDAL. GDAL only produces and recognizes non-spatial tables that conform to http://gdal.org/geopackage_aspatial.html , which is a GDAL-specific extension that was created to address the support of such tables : https://trac.osgeo.org/gdal/ticket/5521 , http://lists.opengeospatial.org/pipermail/geopackage/2014-June/thread.html#22 You can upgrade your DB to aspatial by doing the following : $ sqlite3 av_2495.gpkg INSERT INTO gpkg_contents (table_name, data_type, last_change) SELECT name, 'aspatial', strftime('%Y-%m-%dT%H:%M:%fZ', 'now' ) FROM sqlite_master WHERE type = 'table' AND name NOT LIKE 'gpkg_%' AND name NOT LIKE 'sqlite_%' AND name NOT LIKE 'rtree_%' AND name NOT IN (SELECT table_name FROM gpkg_contents); INSERT INTO gpkg_extensions (table_name, column_name, extension_name, definition, scope) VALUES ( NULL, NULL, 'gdal_aspatial', 'http://gdal.org/geopackage_aspatial.html', 'read-write' ); The original point for the aspatial extension was to be compatible with requirements from metadata, but the latest revision of the GPKG spec has demoted metadata support itself as an extension. So perhaps GDAL could be more lax on opening. Even -- Spatialys - Geospatial professional services http://www.spatialys.com ___ Qgis-user mailing list Qgis-user@lists.osgeo.org List info: http://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user
Re: [Qgis-user] Open geometryless tables from GeoPackage
Yes, compiled and running against gdal master. Do you just drag 'n' drop the geopackage file into QGIS? Do you mind trying this one: http://sogeo.services/tmp/av_2495.gpkg I checked it with "ogrinfo -so av_2495.gpkg" and it only shows the tables with geometry (gdal 1.11 and gdal master). regards Stefan On Wed, Apr 27, 2016 at 9:47 PM, Even Rouault wrote: > Le mercredi 27 avril 2016 21:25:04, Stefan Ziegler a écrit : > > Hi > > > > is there a working approach to open geometryless tables from a geopackage > > file? > > Works for me with https://github.com/qgis/QGIS/pull/3031 applied, but > there's > nothing in it specifically to handle that. > Is your QGIS build against GDAL 2.0 ? (1.11 cannot handle GPKG geometry > less > tables) > > > > > When opening a geopackage file with the standard dialog, there are only > the > > tables shown with geometries. > > > > In the db browser the geometryless tables are shown but cannot be added: > > > > > "/home/stefan/Projekte/qgis-ili2pg-workshop/av_2495.gpkg|layername=Einzelob > > jekte_Einzelobjekt is an invalid layer - not loaded" > > > > best regards > > Stefan > > -- > Spatialys - Geospatial professional services > http://www.spatialys.com > ___ Qgis-user mailing list Qgis-user@lists.osgeo.org List info: http://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user
Re: [Qgis-user] Open geometryless tables from GeoPackage
Le mercredi 27 avril 2016 21:25:04, Stefan Ziegler a écrit : > Hi > > is there a working approach to open geometryless tables from a geopackage > file? Works for me with https://github.com/qgis/QGIS/pull/3031 applied, but there's nothing in it specifically to handle that. Is your QGIS build against GDAL 2.0 ? (1.11 cannot handle GPKG geometry less tables) > > When opening a geopackage file with the standard dialog, there are only the > tables shown with geometries. > > In the db browser the geometryless tables are shown but cannot be added: > > "/home/stefan/Projekte/qgis-ili2pg-workshop/av_2495.gpkg|layername=Einzelob > jekte_Einzelobjekt is an invalid layer - not loaded" > > best regards > Stefan -- Spatialys - Geospatial professional services http://www.spatialys.com ___ Qgis-user mailing list Qgis-user@lists.osgeo.org List info: http://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user
[Qgis-user] Open geometryless tables from GeoPackage
Hi is there a working approach to open geometryless tables from a geopackage file? When opening a geopackage file with the standard dialog, there are only the tables shown with geometries. In the db browser the geometryless tables are shown but cannot be added: "/home/stefan/Projekte/qgis-ili2pg-workshop/av_2495.gpkg|layername=Einzelobjekte_Einzelobjekt is an invalid layer - not loaded" best regards Stefan ___ Qgis-user mailing list Qgis-user@lists.osgeo.org List info: http://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user