Multilinguality (#279)

Improve multilinguality: names in 57 languages, name:latin, name:nonlatin, name_int. Fixes #211 #252 #80.

See #279 for more info.
This commit is contained in:
Jiri Kozel
2017-06-12 17:53:47 +02:00
committed by GitHub
parent 8ff5d10e8b
commit 51bc8fad35
33 changed files with 182 additions and 114 deletions

View File

@@ -3,10 +3,11 @@
-- etldoc: label="layer_poi | <z14_> z14+" ] ;
CREATE OR REPLACE FUNCTION layer_poi(bbox geometry, zoom_level integer, pixel_width numeric)
RETURNS TABLE(osm_id bigint, geometry geometry, name text, name_en text, name_de text, class text, subclass text, "rank" int) AS $$
RETURNS TABLE(osm_id bigint, geometry geometry, name text, name_en text, name_de text, tags hstore, class text, subclass text, "rank" int) AS $$
SELECT osm_id, geometry, NULLIF(name, '') AS name,
COALESCE(NULLIF(name_en, ''), name) AS name_en,
COALESCE(NULLIF(name_de, ''), name, name_en) AS name_de,
tags,
poi_class(subclass, mapping_key) AS class, subclass,
row_number() OVER (
PARTITION BY LabelGrid(geometry, 100 * pixel_width)