City not found if admin boundary with same name exists #4756
Comments
Author: lonvia That is completely intentional. Nominatim tries to merge boundaries and place nodes to avoid duplicate results. |
Author: ppawel[at]fastmail.fm Hmmm, but they are not merged in the second example. Also, when you change the name of relation or place, they are not merged. Plus in the results Olsztyn city is listed as administrative boundary which is rather not intuitive - it looks like there's no city and what's worse in this example is that there's a village listed with the same name in other part of the country so it is confusing to look at those results. Perhaps it should be listed as a city? |
Author: ppawel[at]fastmail.fm Here's another example where it's not merged but relation/place data looks the same: |
Author: ppawel[at]fastmail.fm Could you please address my two comments I added after you closed the ticket? It seems that the current behavior is at least inconsistent (compare the example from the issue description and the one from comment 3). |
Author: twain Nominatim only automatically merges where the admin_level and the feature type match. In the cases you have given they don't match. This preserves the previous behaviour except in cases where they are very clearly duplicates. You can manually tag them to merge (which is preferable) by adding the node to the relation as 'label'. |
Author: Yarl Only 'label' is detected? I think, that 'admin_centre' should also work, if there is no 'label' in relation. |
Author: lonvia 'admin_centre' works as well but only if the name of the place is the same as the name of the relation (because, for example, you wouldn't want the capital of a country be merged with the country itself). Most of the time, 'label' will be the better choice. |
Author: SQ9NIT Then why it merges Olsztyn, but not "Krakw"? For Krakw, there is place=city node in nominatim response, and for Olsztyn not. Maybe there is possibility to add query flag - place=[0|1] - then nominatim will return not merged place and boundary? |
Author: lonvia Actually, name and admin_level must match. In the Krakow case, one is the city the other one is the county, so not matching them up is completely correct. If county and city are actually the same then you must make that somehow clear with the tagging. The currently recommended way to map that is to add a second boundary relation with admin level 8. |
Reporter: ppawel[at]fastmail.fm
[Submitted to the original trac issue database at 4.49pm, Wednesday, 23rd January 2013]
Test search:
http://nominatim.openstreetmap.org/search.php?q=olsztyn
It only shows city's boundary but does not show the city itself in the results.
Compare with this search:
http://nominatim.openstreetmap.org/search.php?q=kortowo
Here both the boundary and place are shown.
The text was updated successfully, but these errors were encountered: