From 00dd98457af1f32e7bb2b9677f6319f72fcfacf9 Mon Sep 17 00:00:00 2001
From: Even Rouault <even.rouault@spatialys.com>
Date: Thu, 23 Jan 2020 13:08:23 +0100
Subject: Database: add a geoid_like value for proj_method column of
 grid_alternatives, fix related entries and simplify/robustify logic to deal
 with EPSG 'Geographic3D to GravityRelatedHeight' methods

---
 data/sql/ignf.sql | 118 +++++++++++++++++++++++++++---------------------------
 1 file changed, 59 insertions(+), 59 deletions(-)

(limited to 'data/sql/ignf.sql')

diff --git a/data/sql/ignf.sql b/data/sql/ignf.sql
index 05664787..c0ffbf50 100644
--- a/data/sql/ignf.sql
+++ b/data/sql/ignf.sql
@@ -1,4 +1,4 @@
---- This file has been generated by scripts/build_db_create_ignf_from_xml.py from the https://geodesie.ign.fr/contenu/fichiers/IGNF.v3.1.0.xml definition file. DO NOT EDIT !
+--- This file has been generated by scripts/build_db_create_ignf_from_xml.py from the http://librairies.ign.fr/geoportail/resources/IGNF.xml definition file. DO NOT EDIT !
 
 INSERT INTO "metadata" VALUES('IGNF.SOURCE', 'https://geodesie.ign.fr/contenu/fichiers/IGNF.v3.1.0.xml');
 INSERT INTO "metadata" VALUES('IGNF.VERSION', '3.1.0');
@@ -2696,8 +2696,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf02-Huahine.mnt',    -- as referenced by the IGNF registry
                             'ggpf02-Huahine.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2710,8 +2710,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggg00v2.mnt',    -- as referenced by the IGNF registry
                             'ggg00v2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2724,8 +2724,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf10-Tahiti.mnt',    -- as referenced by the IGNF registry
                             'ggpf10-Tahiti.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2738,8 +2738,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf02-Raiatea.mnt',    -- as referenced by the IGNF registry
                             'ggpf02-Raiatea.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2752,8 +2752,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggg00_sbv2.mnt',    -- as referenced by the IGNF registry
                             'ggg00_sbv2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2766,8 +2766,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/gg10_smv2.mnt',    -- as referenced by the IGNF registry
                             'gg10_smv2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2780,8 +2780,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RAMG2016.mnt',    -- as referenced by the IGNF registry
                             'RAMG2016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2794,8 +2794,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggker08v2.mnt',    -- as referenced by the IGNF registry
                             'ggker08v2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2808,8 +2808,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggspm06v1.mnt',    -- as referenced by the IGNF registry
                             'ggspm06v1.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2822,8 +2822,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/gg10_sbv2.mnt',    -- as referenced by the IGNF registry
                             'gg10_sbv2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2836,8 +2836,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggguy15.mnt',    -- as referenced by the IGNF registry
                             'ggguy15.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2850,8 +2850,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/metropole/RAF09.mnt',    -- as referenced by the IGNF registry
                             'RAF09.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2864,8 +2864,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf08-Fakarava.mnt',    -- as referenced by the IGNF registry
                             'ggpf08-Fakarava.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2878,8 +2878,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggm00v2.mnt',    -- as referenced by the IGNF registry
                             'ggm00v2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2892,8 +2892,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf10-Moorea.mnt',    -- as referenced by the IGNF registry
                             'ggpf10-Moorea.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2906,8 +2906,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf02-Maupiti.mnt',    -- as referenced by the IGNF registry
                             'ggpf02-Maupiti.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2920,8 +2920,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggg00_lsv2.mnt',    -- as referenced by the IGNF registry
                             'ggg00_lsv2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2934,8 +2934,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggm04v1.mnt',    -- as referenced by the IGNF registry
                             'ggm04v1.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2948,8 +2948,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggg00_smv2.mnt',    -- as referenced by the IGNF registry
                             'ggg00_smv2.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2962,8 +2962,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RALD2016.mnt',    -- as referenced by the IGNF registry
                             'RALD2016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2976,8 +2976,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RAR07_bl.gra',    -- as referenced by the IGNF registry
                             'RAR07_bl.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -2990,8 +2990,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RALS2016.mnt',    -- as referenced by the IGNF registry
                             'RALS2016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3004,8 +3004,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RALDW842016.mnt',    -- as referenced by the IGNF registry
                             'RALDW842016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3018,8 +3018,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf02-Tahaa.mnt',    -- as referenced by the IGNF registry
                             'ggpf02-Tahaa.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3032,8 +3032,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RAGTBT2016.mnt',    -- as referenced by the IGNF registry
                             'RAGTBT2016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3046,8 +3046,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/metropole/RAC09.mnt',    -- as referenced by the IGNF registry
                             'RAC09.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3060,8 +3060,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/RAMART2016.mnt',    -- as referenced by the IGNF registry
                             'RAMART2016.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3074,8 +3074,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('https://geodesie.ign.fr/contenu/fichiers/documentation/grilles/metropole/RAF18.mnt',    -- as referenced by the IGNF registry
                             'RAF18.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 INSERT INTO grid_alternatives(original_grid_name,
@@ -3088,8 +3088,8 @@ INSERT INTO grid_alternatives(original_grid_name,
                     VALUES ('http://geodesie.ign.fr/contenu/fichiers/documentation/grilles/outremer/ggpf02-Bora.mnt',    -- as referenced by the IGNF registry
                             'ggpf02-Bora.gtx',
                             'GTX',
-                            'vgridshift',
-                            1,
+                            'geoid_like',
+                            0,
                             'proj-datumgrid-europe',
                             NULL, NULL, NULL, NULL);
 
-- 
cgit v1.2.3

