diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2021-09-18 11:20:13 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-09-18 11:20:13 +0200 |
| commit | 438ead90d3502f1bf2cb6ed466e75661f33c9445 (patch) | |
| tree | feb3750efa9c76624966ebe0a9a6b4b806cfcfb9 /scripts/build_db.py | |
| parent | f22f3028ccdc87818feb0947f61b9b99914ff83a (diff) | |
| parent | 483717e59333f33e758485c104474ca10e0682ec (diff) | |
| download | PROJ-438ead90d3502f1bf2cb6ed466e75661f33c9445.tar.gz PROJ-438ead90d3502f1bf2cb6ed466e75661f33c9445.zip | |
Merge pull request #2859 from rouault/database_anchor
Database: add a 'anchor' field to geodetic_datum and vertical_datum tables
Diffstat (limited to 'scripts/build_db.py')
| -rwxr-xr-x | scripts/build_db.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/build_db.py b/scripts/build_db.py index 772b2dad..a11fc14b 100755 --- a/scripts/build_db.py +++ b/scripts/build_db.py @@ -201,7 +201,7 @@ def fill_geodetic_datum(proj_db_cursor): for (datum_code, datum_name, ellipsoid_code, prime_meridian_code, publication_date, frame_reference_epoch, deprecated) in res: publication_date = compute_publication_date(datum_code, datum_name, frame_reference_epoch, publication_date) proj_db_cursor.execute( - "INSERT INTO geodetic_datum VALUES (?, ?, ?, NULL, ?, ?, ?, ?, ?, ?, NULL, ?)", (EPSG_AUTHORITY, datum_code, datum_name, EPSG_AUTHORITY, ellipsoid_code, EPSG_AUTHORITY, prime_meridian_code, publication_date, frame_reference_epoch, deprecated)) + "INSERT INTO geodetic_datum VALUES (?, ?, ?, NULL, ?, ?, ?, ?, ?, ?, NULL, NULL, ?)", (EPSG_AUTHORITY, datum_code, datum_name, EPSG_AUTHORITY, ellipsoid_code, EPSG_AUTHORITY, prime_meridian_code, publication_date, frame_reference_epoch, deprecated)) def fill_vertical_datum(proj_db_cursor): @@ -211,7 +211,7 @@ def fill_vertical_datum(proj_db_cursor): for (datum_code, datum_name, publication_date, frame_reference_epoch, deprecated) in res: publication_date = compute_publication_date(datum_code, datum_name, frame_reference_epoch, publication_date) proj_db_cursor.execute( - "INSERT INTO vertical_datum VALUES (?, ?, ?, NULL, ?, ?, NULL, ?)", (EPSG_AUTHORITY, datum_code, datum_name, publication_date, frame_reference_epoch, deprecated)) + "INSERT INTO vertical_datum VALUES (?, ?, ?, NULL, ?, ?, NULL, NULL, ?)", (EPSG_AUTHORITY, datum_code, datum_name, publication_date, frame_reference_epoch, deprecated)) def fill_datumensemble(proj_db_cursor): @@ -235,7 +235,7 @@ def fill_datumensemble(proj_db_cursor): assert ellipsoid_code, datum_code assert prime_meridian_code, datum_code proj_db_cursor.execute( - "INSERT INTO geodetic_datum (auth_name, code, name, description, ellipsoid_auth_name, ellipsoid_code, prime_meridian_auth_name, prime_meridian_code, publication_date, frame_reference_epoch, ensemble_accuracy, deprecated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", (EPSG_AUTHORITY, datum_code, datum_name, None, EPSG_AUTHORITY, ellipsoid_code, EPSG_AUTHORITY, prime_meridian_code, None, None, ensemble_accuracy, deprecated)) + "INSERT INTO geodetic_datum (auth_name, code, name, description, ellipsoid_auth_name, ellipsoid_code, prime_meridian_auth_name, prime_meridian_code, publication_date, frame_reference_epoch, ensemble_accuracy, anchor, deprecated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", (EPSG_AUTHORITY, datum_code, datum_name, None, EPSG_AUTHORITY, ellipsoid_code, EPSG_AUTHORITY, prime_meridian_code, None, None, ensemble_accuracy, None, deprecated)) proj_db_cursor.execute("SELECT datum_code, datum_sequence FROM epsg.epsg_datumensemblemember WHERE datum_ensemble_code = ? ORDER by datum_sequence", (datum_code,)) for member_code, sequence in proj_db_cursor.fetchall(): |
