INSPIRE-MIF / gp-geopackage-encodings

Good practice for GeoPackage encodings of INSPIRE datasets
7 stars 4 forks source link

[END] Colums needed in DatasetDefaultProperties #19

Open heidivanparys opened 3 years ago

heidivanparys commented 3 years ago

Currently, the table DatasetDefaultProperties is defined as

CREATE TABLE "DatasetDefaultProperties" (
  "id" INTEGER,
  "tableName" TEXT,
  "propertyName" TEXT,
  "attribute" TEXT,
  "defaultValue" TEXT
);

Adapting the naming to the GeoPackage spec (see also #17) would give something like:

CREATE TABLE "datasetdefaultvalues" (
  "id" INTEGER,
  "table_name" TEXT,
  "column_name" TEXT,
  "attribute" TEXT,
  "defaultvalue" TEXT
);

attribute is the odd one out, as it actually refers to an XML attribute, and we are dealing with a database here.

When looking at examples, attribute is NULL (for "regular" properties), href (for code list references) or nilReason.

When using a (not yet developed) extension for code lists, see #17, href would not be needed any more.

Regarding nilReason: until today, I thought that providing it was mandatory when a property is void. But when reading the specification again, and when looking at https://github.com/inspire-eu-validation/data/blob/1372bc5a6eb7c7dd5e1c80738d9c38532fb9e68d/schemas/gml-model.md#nilMissing, it seems that provision of that value is actually optional. So could we actually completely drop nilReason? After working with INSPIRE, that piece of information really seems of little use. And then we would be able to drop column attribute completely.