Hi all,
I just incidentally discovered that in such a search, if you enter several keywords separated by comma, you are searching for POIs that fit with ALL the input keywords. Ie. different keywords are searched with a AND between them.
Up to now, I thought that searching with "word1, word2" as keyword was searching for POIs matching "litterally" with the input string, ie. matching with word1 followed by a comma, followed by a space, followed by word2....
Actually, it retrieves all poi matching with "word1" AND matching with "word2", whatever wich one is in first.
This capability to search for POIs matching with several keywords, linked with a "AND" logic, is really interresting. Never mentioned in any of the users manual (at least those in a language I'm (more or less) able to read, french, english, spanish, german, italiano). Maybe it's written in Chinese or Korean documentation.....
On the other hand, do you know if there are syntax for other logical associations ?
Eg, search for POIs matching with ANY of the input keywords ("OR" logic), or search for POIs matching with a keyword but NOT matching with the second ("exclusion" logic), etc...
Quote from: LaurentG on January 19, 2026, 05:33:43 PMHi all,
I just incidentally discovered that in such a search, if you enter several keywords separated by comma, you are searching for POIs that fit with ALL the input keywords. Ie. different keywords are searched with a AND between them.
Up to now, I thought that searching with "word1, word2" as keyword was searching for POIs matching "litterally" with the input string, ie. matching with word1 followed by a comma, followed by a space, followed by word2....
Actually, it retrieves all poi matching with "word1" AND matching with "word2", whatever wich one is in first.
This capability to search for POIs matching with several keywords, linked with a "AND" logic, is really interresting. Never mentioned in any of the users manual (at least those in a language I'm (more or less) able to read, french, english, spanish, german, italiano). Maybe it's written in Chinese or Korean documentation.....
On the other hand, do you know if there are syntax for other logical associations ?
Eg, search for POIs matching with ANY of the input keywords ("OR" logic), or search for POIs matching with a keyword but NOT matching with the second ("exclusion" logic), etc...
Hello, I don't know much about it, but OruxMaps uses mapsforge's native search engine, maybe in their documentation you'll find the answer. https://github.com/mapsforge/mapsforge/blob/master/docs/POI.md
Quote from: Tronpo on January 21, 2026, 09:21:28 AMmaybe in their documentation you'll find the answer
Unfortunately, no (or at least I didn't catch it...), but you gave me the idea to ask the question on mapsforce github site.
See here : https://github.com/mapsforge/mapsforge/discussions/1774
According to answers I got from EMUX (Mapsforge's Author), OruxMaps CANNOT rely only on mapsforge's native search engine APIs.
See on MapsForge discussion mentioned above.
Hi Laurent,
I am not sure which version of oruxmaps you are using. I seem to remember that, a few years ago, you were using the free 4.x one.
On the GP version, offline mapsforge POI search has been reworked a couple of years ago and I don't know if those improvements landed on the free version.
In case it's useful for you, I leave below the help text of the functionality.
Cheers
QuoteThe search area is determined by the current map viewer window. Selecting 'Ignore boundingbox' will search the entire database
Available options:
1. Entering text without selecting any category will search all categories. To search for the exact text, all the words and in the same order, it must be enclosed in single or double quotes. If the text is not enclosed in quotes, results containing all the words will be searched regardless of the order, or any of them if that option is selected.
2. Enter a text and select one or more categories.
3. Select one or more categories without entering any text.
Having now read your conversation with Emux on Github I understand that you can read SQL, so let's be a little bit more technical ;)
QuoteTo search for the exact text, all the words and in the same order, it must be enclosed in single or double quotes
For a search like
'keyword_1 keyword_2', this will generate the following SQL
... WHERE data LIKE '%keyword_1 keyword_2%'QuoteIf the text is not enclosed in quotes, results containing all the words will be searched regardless of the order
for the same keywords, but without quotes, search would be
... WHERE data LIKE '%keyword_1%' AND data LIKE '%keyword_2%'Quoteor any of them if that option is selected
If the user select the option to search for any of the keywords
... WHERE data LIKE '%keyword_1%' OR data LIKE '%keyword_2%'Bonus track, undocumented trick that Jose told me about:
you can search for key/value pairs. For doing so you must put an equal sign in between i.e
email=abc@xyz.com. But there is a gotcha, this will generate the following SQL
... WHERE data LIKE '%email=%abc@xyz.com%'Look at the % character (SQL wildcard) after the equal sign, this means that this search will return records containing 'abc@xyz.com' anywhere AFTER 'email='. It is done on purpose to allow find partial values as well. If the real email address is '123.abc@xyz.com', it will be found.
Hope this helps
Hi @Juanjo,
thank you for your detailed answer.
And yes, I am still on free version. The 7.4.28, to be specific (ie. the latest one).
In this version, there is no option to search for "Any" (as it exist now - I saw it on the 11.0.2beta3)
Moreover, I don't know how it works in the new versions, but I did some tests on my 7.4.28 (I did them with a "manually made" POI base), and actually, the different searches (on the different words) are all certainly done with a sql clause
where data like '%name=%keyword%'
I've been able to determine it, because input keywords are retrieved only if they are AFTER the characters "name=" in the data field. Not only what is inside the name= but also all what is in other "logical fields" (including these field names), provided they are after name=
To give an example, here is the data for a real POI taken from Andorra_oam.osm.poi file
addr:country=FR
addr:postcode=66760
name=Fleuri
name:ca=FlorÃ
normalized_name=fleuri
osm_id=P/342269977
place=hamlet
wikidata=https://www.wikidata.org/entity/Q11935897
wikipedia=https://wikipedia.org/wiki/ca:Mas de FlorÃ
A search on the keyword "Q11935897" retrieves this POI (because Q11935897 is after name= in the data field), but a search on "66760" do NOT retrieve it, because 66760 is BEFORE name= in the data field)
We could also retrieve it with a search on "osm_id", because this substring in in the global data field, and is after name= in the field (even if search on "osm_id" do not make sense....)
In case where the normalized_name= is itself before the name=, the starting point is all what is after normalized_name= (Normal. What is after the substring normalized_name= is in particular after the substring name= ...)
To get such a result, the only solution is that OruxMaps run sql requests "where data like '%name=%keyword%'"
I'll do some tests later on the rev 11.0.2beta3 (running this version in a VM (under Virtualbox), I can set a date in the past, to have the beta version still working)
I just did the test with rev 11.0.2beta3
A lot of differences.
But in particular, when searching on keyword, the search is no more LIKE "%name=%keyword%", but LIKE"%keyword%" since it retrieves any input text, whatever its position in poi_data.data
Eg, in the example of my previous post, a search on the postcode "66760" retrieves the hamlet of Fleuri in rev 11.0.2beta3, while not in rev 7.4.28
And other (great !) enhancements :
- Capability to search for ALL vs ANY of the keywords
- Post-filtering of the result (based on categories)
- Capability to change the POI database used for the search
- Capability to go back to the search screen, in order to change the search parameters and re-run.
Clearly, a very positive evolution.