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:
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?
Solved! Go to Solution.
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
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.
I appreciate the attempt, but doing this does not filter the layers displayed on the map.
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
Thanks @AndreasHall , this seems promising. I’ll give it a check soon. Thanks for your work on this!!
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.