diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2019-11-18 22:33:48 +0100 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2019-11-18 22:41:24 +0100 |
| commit | df339795a8af5487cbff234083a8151c1b3eb181 (patch) | |
| tree | a5e1a8ee5cdadc9eedff51470b02b04c6d4e7fab /scripts/build_db_create_ignf_from_xml.py | |
| parent | b063035618a00218daed43260750ee4e60d5c84e (diff) | |
| download | PROJ-df339795a8af5487cbff234083a8151c1b3eb181.tar.gz PROJ-df339795a8af5487cbff234083a8151c1b3eb181.zip | |
Database: add a publication_date column to geodetic_datum and vertical_datum
Populated from realization_epoch column from EPSG
The 'publication_date' naming is from OGC Topic 2, and hasn't been yet adopted
by the EPSG dataset.
See http://docs.opengeospatial.org/as/18-005r4/18-005r4.html , Annex G, clause 11
and https://32zn56499nov99m251h4e9t8-wpengine.netdna-ssl.com/wp-content/uploads/2019/09/EPSG-relational-data-model-changes_2019-09-18.pdf
Diffstat (limited to 'scripts/build_db_create_ignf_from_xml.py')
| -rwxr-xr-x | scripts/build_db_create_ignf_from_xml.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/build_db_create_ignf_from_xml.py b/scripts/build_db_create_ignf_from_xml.py index 33302bc3..6e4ffd1d 100755 --- a/scripts/build_db_create_ignf_from_xml.py +++ b/scripts/build_db_create_ignf_from_xml.py @@ -144,7 +144,7 @@ def ingest_datums(root, all_sql, mapEllpsId, mapPmId): assert ellpsCode in mapEllpsId # We sheat by using EPSG:1262 = World for area of use - sql = """INSERT INTO "geodetic_datum" VALUES('IGNF','%s','%s',NULL,NULL,'%s','%s','%s','%s','EPSG','1262',0);""" % (id, names[0], mapEllpsId[ellpsCode][0], mapEllpsId[ellpsCode][1], mapPmId[pmCode][0], mapPmId[pmCode][1]) + sql = """INSERT INTO "geodetic_datum" VALUES('IGNF','%s','%s',NULL,NULL,'%s','%s','%s','%s','EPSG','1262',NULL,0);""" % (id, names[0], mapEllpsId[ellpsCode][0], mapEllpsId[ellpsCode][1], mapPmId[pmCode][0], mapPmId[pmCode][1]) all_sql.append(sql) mapDatumId[id] = ('IGNF', id) @@ -154,7 +154,7 @@ def ingest_datums(root, all_sql, mapEllpsId, mapPmId): id = node.attrib['id'] names = [_name.text for _name in node.iter('name')] - sql = """INSERT INTO "vertical_datum" VALUES('IGNF','%s','%s',NULL,NULL,'EPSG','1262',0);"""% (id, names[0]) + sql = """INSERT INTO "vertical_datum" VALUES('IGNF','%s','%s',NULL,NULL,'EPSG','1262',NULL,0);"""% (id, names[0]) all_sql.append(sql) mapVerticalDatumId[id] = ('IGNF', id) |
