Dashboard map doesn't honor web map's filter

1093
5
Jump to solution
12-19-2022 12:38 PM
Matt-Goodman
Occasional Contributor

Hi, I have a web map that contains a Map Image Layer of crime incident points. In my web map, my layer has a definition query (filter) omitting all records where [MyLatitudeColumn]='48.00' (all records that had '0' or Null latitudes were field-calculated to this nice rounded-off number in order to handle them and keep them within the full set of features). So, in my web map, these features are not displayed, which is how I want it. The web map also has a duplicate layer in its table of contents that does not omit these same records (contains the full set of features), but it is not visibly displayed on the map (this is how I want it). 

Web map: 

MattGoodman1_0-1671482454576.png

 

However, I have created a dashboard from my web map and, as soon as I configure a 'Selector' in the dashboard, it seems to then ignore the web map's filter on my display layer, and the previously omitted features display. When I initially add the web map to my dashboard, it seems to be honoring the filter...it only ignores the filter when I build a 'Selector' widgit that utilizes the layer.

Is this expected behavior? Is there some way to work around this? 

0 Kudos
1 Solution

Accepted Solutions
AndreasHall
Esri Contributor

I did some testing on my own now. I had a foggy memory about map services behaving differently in Dashboards whether it was added to a maps as a service or as a layer. When I tested now, I get different behavior. When configuring a selector action towards a map service I can reproduce your behavior but if I configure it against a layer from a map service that was added to the map independently, the dashboard work as expected. 

Instead of adding the whole map service (2 in the image below), just add the URL of the layer to your map (1 in the image below). The URL should look something like this: https://_______________/arcgis/rest/services/F%C3%B6retagsdata_G%C3%A4vleborg_MIL1/MapServer/0

AndreasHall_0-1671609270917.png

 

View solution in original post

5 Replies
AndreasHall
Esri Contributor

I do not know if this is expected behavior but a possible workaround could be to add the filter you have applied to the map to the selector in the dashboard. This works for both category and number selectors.

AndreasHall_0-1671534525561.png

 

0 Kudos
Matt-Goodman
Occasional Contributor

I appreciate the attempt, but doing this does not filter the layers displayed on the map. 

AndreasHall
Esri Contributor

I did some testing on my own now. I had a foggy memory about map services behaving differently in Dashboards whether it was added to a maps as a service or as a layer. When I tested now, I get different behavior. When configuring a selector action towards a map service I can reproduce your behavior but if I configure it against a layer from a map service that was added to the map independently, the dashboard work as expected. 

Instead of adding the whole map service (2 in the image below), just add the URL of the layer to your map (1 in the image below). The URL should look something like this: https://_______________/arcgis/rest/services/F%C3%B6retagsdata_G%C3%A4vleborg_MIL1/MapServer/0

AndreasHall_0-1671609270917.png

 

Matt-Goodman
Occasional Contributor

Thanks @AndreasHall , this seems promising. I’ll give it a check soon. Thanks for your work on this!!

0 Kudos
Matt-Goodman
Occasional Contributor

Indeed, I can confirm this work-around works: must be a feature layer. Still, it's a little disappointing that you can't do a very basic filter/definition query, just because it's a map service.