Open fhb1990 opened 3 years ago
Do views need to be added to
gpkg_contents
?
Yes, views should be added to gpkg_contents
, see also https://www.geopackage.org/spec/#_contents . E.g.
The
gpkg_contents
table is intended to provide a list of all geospatial contents in a GeoPackage. It provides identifying and descriptive information that an application can display to a user as a menu of geospatial data that is available for access and/or update.
and
The
table_name
column value in agpkg_contents
table row SHALL contain the name of a SQLite table or view.
If you do not add a view to the gpkg_contents
table, it e.g. won't show up as a layer in QGIS, I noticed.
In the Netherlands there has been interest in delivering Geology data in Geopackage format. As written in issue #9, we have tried to follow the encoding rules found here to create a template for GE data. This has resulted in a set of SQL statements which should result in a working empty Geopackage template file for the theme Geology (like the ones for AU and GN on this page).
By following the encoding rules specified by the link above, the added file has been created. The only thing that is missing are the association roles between the classes. These associations have to be added as related tables and views. This then has consequences for the tables
gpkg_contents
,gpkg_extensions
,gpkg_data_columns
andgpkgext_relations
, as new rows need to be added in these tables.geology gpkg 2021.zip
Some thoughts arose over making the file, some from ambiguity in the encoding rules. These are written below.
gpkg_contents
?Geophysics
that aggregate into the Geology featureTypeGeologicCollection
need to be added?Quantity
andDirectPosition
?