Separating house from associated businesses in search results #3602
Replies: 4 comments 2 replies
-
Some users only want postal addresses, some only the shop names. By default Nominatim returns a mix of both. On the website you link, click 'Advanced options' and play with the 'layer' parameter. https://nominatim.org/release-docs/latest/api/Search/#result-restriction |
Beta Was this translation helpful? Give feedback.
-
Though it still strange that the places don't have the same type in my local DB. |
Beta Was this translation helpful? Give feedback.
-
OSM doesn't have distinct objects for addresses. They are always an attribute of another object (sometimes otherwise untagged, though). Nominatim follows the same schema because it still holds a 1:1 relationship with OSM objects. So, when you search with layer "address" you get all objects that have a full address. In your example that amounts to one building and 4 POIs. Nominatim will not do any further filtering because it cannot really know which of the four OSM object you are really interested in. If you have imported your local database with the "address" style, then it's not surprising you don't get the POI classifications. You haven't imported them. This style will only get the address information and classify everything as |
Beta Was this translation helpful? Give feedback.
-
I will try to filter out point results that have the osm_type of 'N'. Hopefully in my area of interest all buildings will have some sort of shape to them. For a more general solution I have opened an issue #3603 . |
Beta Was this translation helpful? Give feedback.
-
Searching for a house, I am having hard time separating it from the businesses that are found with it.
On the website, the addresses for the businesses found do have a specific Type, like "shop:car_repair". But same addresses, when I get them from the local Nominatim, just have the category of "place" "house". Am I required to do something to see the actual specific types?
It is also strange that the shops are returned at all, given that their addresses appear to be distinct, having an extra part on top of the house_number that is not in the query. After all, when I am searching for a city I don't get returned all the streets in it. Does Nominatim handle shops in a special way or am I doing something wrong?
Beta Was this translation helpful? Give feedback.
All reactions