This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

Curl gives empty response

0

What am I doing wrong here?

curl 'http://nominatim.openstreetmap.org/?q=Wokingham,%20Berkshire,%20England&format=json'

gives the empty response

[]

asked 26 May '17, 13:44

nigelhorne's gravatar image

nigelhorne
11112
accept rate: 0%


One Answer:

2

Nominatim does not calculate a relationship between Wokingham and Berkshire.

I don't know why that is but I think it must be the problem with http://nominatim.openstreetmap.org/?q=Wokingham,England&format=json returning the reasonable result.

answered 26 May '17, 16:45

maxerickson's gravatar image

maxerickson
12.7k1083176
accept rate: 32%

Thanks for your reply. Wokingham is in Berkshire, so it should work.

(26 May '17, 17:25) nigelhorne

Berkshire no longer exists, and is certainly no longer a standard part of a postal address. Its possible that the ceremonial county of Berkshire (which does still have some role) has not been added to OSM, or that Nominatim does not use such information. Similar problems exist for places such as Hayes (Middlesex) and Kingston (Surrey). It is not clear that OSM can support older geographies such as these. Most countries tend to keep admin & address geographies aligned, but not the UK.

(26 May '17, 20:41) SK53 ♦

The ceremonial county is present: http://nominatim.openstreetmap.org/?q=Berkshire,England&format=json

So that fills out the answer, Nominatim is not including the ceremonial county in the address hierarchy (and any query parsed as looking for 'children' of Berkshire will return 0 results).

(26 May '17, 20:59) maxerickson

Source code available on GitHub .