aboutsummaryrefslogtreecommitdiff
path: root/data/sql/conversion_triggers.sql
diff options
context:
space:
mode:
authorKristian Evers <kristianevers@gmail.com>2019-05-01 18:40:04 +0200
committerGitHub <noreply@github.com>2019-05-01 18:40:04 +0200
commiteeda5f7e5fd94a0cdcbf90df1f0b04a090f4c037 (patch)
tree86a8e2a7277351415e0836e37a975b81afd10b1c /data/sql/conversion_triggers.sql
parente2b291c0c2a684313143eaf334fbf1161075b449 (diff)
parent8c025212b364cca181f1b436068516313032182c (diff)
downloadPROJ-eeda5f7e5fd94a0cdcbf90df1f0b04a090f4c037.tar.gz
PROJ-eeda5f7e5fd94a0cdcbf90df1f0b04a090f4c037.zip
Reduce database size (#1438)
Reduce database size
Diffstat (limited to 'data/sql/conversion_triggers.sql')
-rw-r--r--data/sql/conversion_triggers.sql4
1 files changed, 2 insertions, 2 deletions
diff --git a/data/sql/conversion_triggers.sql b/data/sql/conversion_triggers.sql
index 86eb1afd..001a8174 100644
--- a/data/sql/conversion_triggers.sql
+++ b/data/sql/conversion_triggers.sql
@@ -1,8 +1,8 @@
--- This file has been generated by scripts/build_db.py. DO NOT EDIT !
CREATE TRIGGER conversion_method_check_insert_trigger
-BEFORE INSERT ON conversion
-FOR EACH ROW BEGIN
+INSTEAD OF INSERT ON conversion
+BEGIN
SELECT RAISE(ABORT, 'insert on conversion violates constraint: bad parameters for Lambert Conic Conformal (2SP)')
WHERE NEW.deprecated != 1 AND NEW.method_auth_name = 'EPSG' AND NEW.method_code = '9802' AND (NEW.method_name != 'Lambert Conic Conformal (2SP)' OR NEW.param1_auth_name != 'EPSG' OR NEW.param1_code != '8821' OR NEW.param1_name != 'Latitude of false origin' OR NEW.param1_value IS NULL OR NEW.param1_uom_auth_name IS NULL OR NEW.param1_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param1_uom_auth_name AND code = NEW.param1_uom_code) != 'angle' OR NEW.param2_auth_name != 'EPSG' OR NEW.param2_code != '8822' OR NEW.param2_name != 'Longitude of false origin' OR NEW.param2_value IS NULL OR NEW.param2_uom_auth_name IS NULL OR NEW.param2_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param2_uom_auth_name AND code = NEW.param2_uom_code) != 'angle' OR NEW.param3_auth_name != 'EPSG' OR NEW.param3_code != '8823' OR NEW.param3_name != 'Latitude of 1st standard parallel' OR NEW.param3_value IS NULL OR NEW.param3_uom_auth_name IS NULL OR NEW.param3_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param3_uom_auth_name AND code = NEW.param3_uom_code) != 'angle' OR NEW.param4_auth_name != 'EPSG' OR NEW.param4_code != '8824' OR NEW.param4_name != 'Latitude of 2nd standard parallel' OR NEW.param4_value IS NULL OR NEW.param4_uom_auth_name IS NULL OR NEW.param4_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param4_uom_auth_name AND code = NEW.param4_uom_code) != 'angle' OR NEW.param5_auth_name != 'EPSG' OR NEW.param5_code != '8826' OR NEW.param5_name != 'Easting at false origin' OR NEW.param5_value IS NULL OR NEW.param5_uom_auth_name IS NULL OR NEW.param5_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param5_uom_auth_name AND code = NEW.param5_uom_code) != 'length' OR NEW.param6_auth_name != 'EPSG' OR NEW.param6_code != '8827' OR NEW.param6_name != 'Northing at false origin' OR NEW.param6_value IS NULL OR NEW.param6_uom_auth_name IS NULL OR NEW.param6_uom_code IS NULL OR (SELECT type FROM unit_of_measure WHERE auth_name = NEW.param6_uom_auth_name AND code = NEW.param6_uom_code) != 'length' OR NEW.param7_auth_name IS NOT NULL OR NEW.param7_code IS NOT NULL OR NEW.param7_name IS NOT NULL OR NEW.param7_value IS NOT NULL OR NEW.param7_uom_auth_name IS NOT NULL OR NEW.param7_uom_code IS NOT NULL);