aboutsummaryrefslogtreecommitdiff
path: root/data/sql/proj_db_table_defs.sql
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-09-17 19:19:37 +0200
committerEven Rouault <even.rouault@spatialys.com>2021-09-17 19:20:54 +0200
commit2db54cc09a6587eba855aebac05baa1ae5130c2c (patch)
treee00063b02d5db66097b37444849694871dab1d68 /data/sql/proj_db_table_defs.sql
parenta3e412995df7dae2c8ef13d2682e03b770edcb75 (diff)
downloadPROJ-2db54cc09a6587eba855aebac05baa1ae5130c2c.tar.gz
PROJ-2db54cc09a6587eba855aebac05baa1ae5130c2c.zip
Database: add a 'anchor' field to geodetic_datum and vertical_datum tables
Update database layout version number to 1.2 consequently This new capability will be used by IAU planetary CRS (refs #2601)
Diffstat (limited to 'data/sql/proj_db_table_defs.sql')
-rw-r--r--data/sql/proj_db_table_defs.sql4
1 files changed, 3 insertions, 1 deletions
diff --git a/data/sql/proj_db_table_defs.sql b/data/sql/proj_db_table_defs.sql
index f353e4e8..9155fd8f 100644
--- a/data/sql/proj_db_table_defs.sql
+++ b/data/sql/proj_db_table_defs.sql
@@ -155,6 +155,7 @@ CREATE TABLE geodetic_datum (
publication_date TEXT, --- YYYY-MM-DD format
frame_reference_epoch FLOAT, --- only set for dynamic datum, and should be set when it is a dynamic datum
ensemble_accuracy FLOAT CHECK (ensemble_accuracy IS NULL OR ensemble_accuracy > 0), --- only for a datum ensemble. and should be set when it is a datum ensemble
+ anchor TEXT,
deprecated BOOLEAN NOT NULL CHECK (deprecated IN (0, 1)),
CONSTRAINT pk_geodetic_datum PRIMARY KEY (auth_name, code),
CONSTRAINT fk_geodetic_datum_ellipsoid FOREIGN KEY (ellipsoid_auth_name, ellipsoid_code) REFERENCES ellipsoid(auth_name, code),
@@ -191,6 +192,7 @@ CREATE TABLE vertical_datum (
publication_date TEXT CHECK (NULL OR length(publication_date) = 10), --- YYYY-MM-DD format
frame_reference_epoch FLOAT, --- only set for dynamic datum, and should be set when it is a dynamic datum
ensemble_accuracy FLOAT CHECK (ensemble_accuracy IS NULL OR ensemble_accuracy > 0), --- only for a datum ensemble. and should be set when it is a datum ensemble
+ anchor TEXT,
deprecated BOOLEAN NOT NULL CHECK (deprecated IN (0, 1)),
CONSTRAINT pk_vertical_datum PRIMARY KEY (auth_name, code)
) WITHOUT ROWID;
@@ -247,7 +249,7 @@ CREATE TABLE geodetic_crs(
code INTEGER_OR_TEXT NOT NULL CHECK (length(code) >= 1),
name TEXT NOT NULL CHECK (length(name) >= 2),
description TEXT,
- type TEXT NOT NULL CHECK (type IN ('geographic 2D', 'geographic 3D', 'geocentric')),
+ type TEXT NOT NULL CHECK (type IN ('geographic 2D', 'geographic 3D', 'geocentric', 'other')),
coordinate_system_auth_name TEXT,
coordinate_system_code INTEGER_OR_TEXT,
datum_auth_name TEXT,