]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/Geocode.php
cleanup of SQL for readability. No logic change
[nominatim.git] / lib / Geocode.php
index c234c5f2d7a3b9414a8a91b85671488c8fe9ec55..a8e4083b2c4883238e9d55cf7de0026c23619a17 100644 (file)
@@ -532,7 +532,7 @@ class Geocode
             $sSQL .= " UNION ";
             $sSQL .= "SELECT ";
             $sSQL .= "  'W' AS osm_type, ";
-            $sSQL .= "  place_id AS osm_id, ";
+            $sSQL .= "  osm_id, ";
             $sSQL .= "  'place' AS class, ";
             $sSQL .= "  'house' AS type, ";
             $sSQL .= "  null AS admin_level, ";
@@ -563,6 +563,7 @@ class Geocode
             $sSQL .= "  null AS extra_place ";
             $sSQL .= "  FROM (";
             $sSQL .= "     SELECT ";
+            $sSQL .= "         osm_id, ";
             $sSQL .= "         place_id, ";
             $sSQL .= "         calculated_country_code, ";
             $sSQL .= "         CASE ";             // interpolate the housenumbers here