Select to view content in your preferred language

Substring query issue in webmaps portal searches

381
3
01-26-2025 11:58 PM
mmoosbac94
Emerging Contributor

Hello everyone,

We have a question regarding more complex portal queries for searching web maps.

For example, we have a web map titled "japan", and when we execute a query like:
orgid:\(organizationID) AND type:"Web Map" AND \(input)
with the input set to "jap", we correctly retrieve the "japan" web map as a result.

However, when we use "apan" as the input, the query does not return the "japan" web map.

We’d like to know if we can modify our query to allow substring searches, making our web map search more flexible. We’ve already tried solutions such as adding a wildcard (*) before the input (e.g., *apan*), but so far, nothing has worked.

Thanks,
Marvin

 

0 Kudos
3 Replies
ZacharyKline
Esri Contributor

Hi Marvin, thanks for the question.

Based on this documentation, it sounds like you may want to try the q parameter for your input since that is used for full-text search, and for cases where the result depends on a relevance score. In addition, that documentation helps explain in detail how our search engine works.

Finally, I'm not sure if you know this but we have a method Portal.findItems(queryParameters:) that could be used as well.

Thank you.

0 Kudos
mmoosbac94
Emerging Contributor

Hi @ZacharyKline,

thanks for the quick reply. Yes, we are using the Portal.findItems(queryParameters) function and we need to create the queryParameters for full/substring search. We read the documentation and tried out the q parameter but without success, so we do not get any result back. But as mentioned just using "AND \(input) we do get results but not for substrings. Maybe you could give us an example regarding this approach:

PortalQueryParameters(query: "orgid:\(organizationID) AND type:"Web Map" AND \(input)")

Thank you,
Marvin

0 Kudos
Shai_V
by
New Contributor

@mmoosbac94,

Please contact Esri support services and request an enhancement for this along with your use case.

Thank you!

Shaivalya