Select to view content in your preferred language

How to write a URL Parameter with a LIKE clause?

262
2
11-24-2025 03:32 PM
LewisBernier
New Contributor

I am trying to use the WHERE parameter in the URL of my experience view

I have this part of my URL: data_filter=dataSource_1-198860de052-layer-7:Brands LIKE '%Pitman%'
Which after encoding looks like: data_filter=dataSource_1-198860de052-layer-7%3ABrands%2520LIKE%2520%27%2525pitman%2525%27
 
This works for entries where the full text of the Brands column is "Pitman", but not if it contains "Pitman" but also other text. Is it possible to make it actually do partial matching?
 
Thanks
0 Kudos
2 Replies
MappyIan
Frequent Contributor

I wonder if this is related to problems with the underlying search mechanism used across the platform.  There are a few posts about various search issues in the forums, couple linked below:

https://community.esri.com/t5/arcgis-experience-builder-questions/experience-builder-search-function...

https://community.esri.com/t5/arcgis-online-questions/text-searching-behaviour-non-intuitive-to-end/...

It seems the whole 'contains' type search doesn't work in a way that end users would expect.  Not sure if this helps but it might be worth logging an Idea on here if you can't get it to work or maybe log a support case with your local Esri support team.

0 Kudos
Shen_Zhang
Esri Contributor

It appears to be related to character encoding. I was able to make it work by using the LIKE operator to filter country affiliation names that contain “us”.

Screenshot 2025-12-24 at 16.21.44.png

This is the URL parameter I use: 

data_filter=dataSource_2-18de4d6a844-layer-2:COUNTRYAFF%20LIKE%20%27%25us%25%27

After decoding it, it looks like: 

data_filter=dataSource_2-18de4d6a844-layer-2:COUNTRYAFF LIKE '%us%'

I tried to decode your encoded URL. Here's what it suggests:

data_filter=dataSource_1-198860de052-layer-7:Brands%20LIKE%20'%25pitman%25'

Still has some encoded characters in it.  

Shen Zhang
0 Kudos