You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: data/sql/consistency_checks_triggers.sql
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -346,6 +346,12 @@ FOR EACH ROW BEGIN
346
346
SELECT RAISE(ABORT, 'insert on grid_transformation violates constraint: target_crs(auth_name, code) not found')
347
347
WHERE NOT EXISTS (SELECT1FROM crs_view WHEREcrs_view.auth_name=NEW.target_crs_auth_nameANDcrs_view.code=NEW.target_crs_code);
348
348
349
+
SELECT RAISE(ABORT, 'insert on grid_transformation violates constraint: interpolation_crs(auth_name, code) not found')
350
+
WHERENEW.interpolation_crs_codeIS NOT NULLAND NOT EXISTS (SELECT1FROM crs_view WHEREcrs_view.auth_name=NEW.interpolation_crs_auth_nameANDcrs_view.code=NEW.interpolation_crs_code);
351
+
352
+
SELECT RAISE(ABORT, 'insert on grid_transformation violates constraint: interpolation_crs must be a GeodeticCRS on non-TIN shift based files')
353
+
WHERENEW.method_name NOT LIKE'%JSON%'ANDNEW.interpolation_crs_codeIS NOT NULLAND NOT EXISTS (SELECT1FROM geodetic_crs WHEREgeodetic_crs.auth_name=NEW.interpolation_crs_auth_nameANDgeodetic_crs.code=NEW.interpolation_crs_code);
354
+
349
355
SELECT RAISE(ABORT, 'insert on grid_transformation violates constraint: source_crs must not be deprecated when grid_transformation is not deprecated')
350
356
WHERE EXISTS(SELECT1FROM crs_view crs WHEREcrs.auth_name=NEW.source_crs_auth_nameANDcrs.code=NEW.source_crs_codeANDcrs.deprecated!=0) ANDNEW.deprecated=0AND NOT (NEW.auth_name='ESRI');
351
357
SELECT RAISE(ABORT, 'insert on grid_transformation violates constraint: target_crs must not be deprecated when grid_transformation is not deprecated')
Copy file name to clipboardExpand all lines: data/sql/grid_transformation.sql
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1762,6 +1762,12 @@ INSERT INTO "grid_transformation" VALUES('EPSG','10697','EUREF-FIN to N2000 heig
1762
1762
INSERT INTO "usage" VALUES('EPSG','22014','grid_transformation','EPSG','10697','EPSG','3333','EPSG','1133');
1763
1763
INSERT INTO "grid_transformation" VALUES('EPSG','10698','EUREF-FIN to EUREF-FIN + N2000 height (2)','Replaces EUREF-FIN to EUREF-FIN + N2000 height (1) (code 10696). Reversible alternative to EUREF-FIN to N2000 height (2) (code 10697). File also available in 3 ASCII formats.','EPSG','1124','Geog3D to Geog2D+GravityRelatedHeight (gtg)','EPSG','10689','EPSG','10692',0.014,'EPSG','8666','Geoid (height correction) model file','fi_nls_fin2023n2000.tif',NULL,NULL,NULL,NULL,'EPSG','10690','NLS-Fin 2023',0);
1764
1764
INSERT INTO "usage" VALUES('EPSG','22015','grid_transformation','EPSG','10698','EPSG','3333','EPSG','1270');
1765
+
INSERT INTO "grid_transformation" VALUES('EPSG','10703','KKJ / Finland Uniform Coordinate System to EUREF-FIN / TM35FIN(E,N) (1)','This YKJ to ETRS-TM35FIN TINshift transformation is the recommended method for KKJ to EUREF-FIN transformations, to be used in preference to transformation KKJ to ETRS89 (2) (code 10098).','EPSG','1138','Cartesian Grid Offsets by TIN Interpolation (JSON)','EPSG','2393','EPSG','3067',0.03,'EPSG','1064','TIN offset file','fi_nls_ykj_etrs35fin.json',NULL,NULL,NULL,NULL,NULL,NULL,'NLS-FIN TINshift',0);
1766
+
INSERT INTO "usage" VALUES('EPSG','22055','grid_transformation','EPSG','10703','EPSG','3333','EPSG','1273');
1767
+
INSERT INTO "grid_transformation" VALUES('EPSG','10704','N43 height to N60 height (1)','Accuracy has not been determined.','EPSG','1137','Vertical Offset by TIN Interpolation (JSON)','EPSG','8675','EPSG','5717',999.0,'EPSG','1064','TIN offset file','fi_nls_n43_n60.json',NULL,NULL,NULL,NULL,'EPSG','2393','NLS-Fin TINshift',0);
1768
+
INSERT INTO "usage" VALUES('EPSG','22018','grid_transformation','EPSG','10704','EPSG','4522','EPSG','1059');
1769
+
INSERT INTO "grid_transformation" VALUES('EPSG','10705','N60 height to N2000 height (1)','Recommended method for N60<>N2000 trasformations, as more accurate than concatenating geoid models.','EPSG','1137','Vertical Offset by TIN Interpolation (JSON)','EPSG','5717','EPSG','3900',0.005,'EPSG','1064','TIN offset file','fi_nls_n60_n2000.json',NULL,NULL,NULL,NULL,'EPSG','2393','NLS-Fin TINshift',0);
1770
+
INSERT INTO "usage" VALUES('EPSG','22201','grid_transformation','EPSG','10705','EPSG','3333','EPSG','1059');
1765
1771
INSERT INTO "grid_transformation" VALUES('EPSG','15486','CH1903 to CH1903+ (1)','For improved accuracy (0.01m) use CHENyx06 interpolation programme FINELTRA. File CHENyx06 replaced by CHENyx06a; there is a small area at the border of the data where some more real data has been introduced. swisstopo consider the change insignificant.','EPSG','9615','NTv2','EPSG','4149','EPSG','4150',0.2,'EPSG','8656','Latitude and longitude difference file','CHENyx06a.gsb',NULL,NULL,NULL,NULL,NULL,NULL,'BfL-Che',0);
1766
1772
INSERT INTO "usage" VALUES('EPSG','11497','grid_transformation','EPSG','15486','EPSG','1286','EPSG','1085');
1767
1773
INSERT INTO "grid_transformation" VALUES('EPSG','15488','RRAF 1991 to IGN 1988 MG height (1)','May be used for transformations from WGS 84 to IGN 1988 MG. Accuracy at each 0.025 deg x 0.025 degree grid node is given within the geoid model file.','EPSG','9664','Geographic3D to GravityRelatedHeight (IGN1997)','EPSG','4973','EPSG','5617',0.2,'EPSG','8666','Geoid (height correction) model file','ggg00_mg.txt',NULL,NULL,NULL,NULL,NULL,NULL,'IGN Glp MG',1);
INSERT INTO"concatenated_operation"VALUES('PROJ','KKJ_TO_ETRS89','KKJ to ETRS89 (using PROJ:YKJ_TO_ETRS35FIN)','Transformation based on a triangulated irregular network','EPSG','4123','EPSG','4258',NULL,NULL,0);
21
+
INSERT INTO"concatenated_operation"VALUES('PROJ','KKJ_TO_ETRS89','KKJ to ETRS89 (using EPSG:10703)','Transformation based on a triangulated irregular network','EPSG','4123','EPSG','4258',NULL,NULL,0);
INSERT INTO"concatenated_operation"VALUES('PROJ','KKJ_TO_EUREF_FIN','KKJ to EUREF-FIN (using PROJ:YKJ_TO_ETRS35FIN)','Transformation based on a triangulated irregular network','EPSG','4123','EPSG','10690',NULL,NULL,0);
35
+
INSERT INTO"concatenated_operation"VALUES('PROJ','KKJ_TO_EUREF_FIN','KKJ to EUREF-FIN (using EPSG:10703)','Transformation based on a triangulated irregular network','EPSG','4123','EPSG','10690',NULL,NULL,0);
proj_db_cursor.execute("SELECT coord_op_code, coord_op_name, coord_op_method_code, coord_op_method_name, source_crs_code, target_crs_code, coord_op_accuracy, coord_tfm_version, epsg_coordoperation.deprecated, epsg_coordoperation.remarks FROM epsg.epsg_coordoperation LEFT JOIN epsg.epsg_coordoperationmethod USING (coord_op_method_code) WHERE coord_op_type IN ('transformation', 'point motion operation') AND coord_op_method_code NOT IN (1131, 1136) AND (coord_op_method_name LIKE 'Geographic3D to%' OR coord_op_method_name LIKE 'Geog3D to%' OR coord_op_method_name LIKE 'Point motion by grid%' OR coord_op_method_name LIKE 'Vertical % by %grid%' OR coord_op_method_name IN ('NADCON', 'NADCON5 (2D)', 'NADCON5 (3D)', 'NTv1', 'NTv2', 'VERTCON', 'Geocentric translation by Grid Interpolation (IGN)', 'Geographic3D Offset by velocity grid (NTv2_Vel)', 'New Zealand Deformation Model'))")
695
+
proj_db_cursor.execute("SELECT coord_op_code, coord_op_name, coord_op_method_code, coord_op_method_name, source_crs_code, target_crs_code, coord_op_accuracy, coord_tfm_version, epsg_coordoperation.deprecated, epsg_coordoperation.remarks FROM epsg.epsg_coordoperation LEFT JOIN epsg.epsg_coordoperationmethod USING (coord_op_method_code) WHERE coord_op_type IN ('transformation', 'point motion operation') AND coord_op_method_code NOT IN (1131, 1136) AND (coord_op_method_name LIKE 'Geographic3D to%' OR coord_op_method_name LIKE 'Geog3D to%' OR coord_op_method_name LIKE 'Point motion by grid%' OR coord_op_method_name LIKE 'Vertical % by %grid%' OR coord_op_method_name IN ('NADCON', 'NADCON5 (2D)', 'NADCON5 (3D)', 'NTv1', 'NTv2', 'VERTCON', 'Geocentric translation by Grid Interpolation (IGN)', 'Geographic3D Offset by velocity grid (NTv2_Vel)', 'New Zealand Deformation Model', 'Cartesian Grid Offsets by TIN Interpolation (JSON)', 'Vertical Offset by TIN Interpolation (JSON)'))")
0 commit comments