Arcade Statement for Symbology not "sticking" in New Map Viewer

1448
12
02-06-2023 09:11 AM
Labels (3)
LeahClark
New Contributor III

I am attempting to use Arcade to symbolize my data on a Feature Layer in the New Map Viewer. The Arcade statement appears to be working correctly, and I see the correct output symbolized when it is applied. However, once it is saved and the page is refreshed, the data is no longer symbolized and falls into the 'Other' category. If I try to move it up from the 'Other' category to symbolize and save again, I see the same behavior on refreshing the page. 

Here is my arcade statement:

 

if ($feature.STATUS == 'Temporary Removal') {
     return "Temporary Removal" }
else if ($feature.STATUS == 'Active' && $feature.DaysSinceInspection == '< 60 days') {
     return "< 60 days" }
else if ($feature.STATUS == 'Active' && $feature.DaysSinceInspection == '60-90 days') {
     return "60-90 days" }
else if ($feature.STATUS == 'Active' && $feature.DaysSinceInspection == '> 90 days') {
     return "> 90 days" }
else {
     return "None of these conditions" }

 

 

After the Arcade statement is applied to the symbology, it automatically returns all of the records under this value (which is accurate to what I am expecting to see):

LeahChrisman_0-1675702838995.png

 

I save the map from the left side panel in the New Map Viewer (I have also tried doing this exact same thing under the visualization tab in the Feature Layer item details, which warrant the same results):

LeahChrisman_1-1675702965259.png

 

Then when I go to refresh the map, it is blank and the symbology has disappeared. Upon inspecting the symbology I see that the original value has 0 records and the same value exists under the 'Other' category now:

LeahChrisman_2-1675703136954.png

 

I moved the symbology up out of the other category, and the points were added to the map:

LeahChrisman_3-1675703256728.png

 

I save again, reload the map, and again it is blank. Inspecting the symbology shows the same issue has happened again:

LeahChrisman_4-1675703343494.png

 

Has anyone else encountered a similar issue? Is there a problem with my arcade statement or my method of symbolizing that might be causing this? Thanks!

12 Replies
jcarlson
MVP Esteemed Contributor

Is DaysSinceInspection actually a string? Why not just symbolize the features directly off that field and filter out non-active statuses?

- Josh Carlson
Kendall County GIS
0 Kudos
LeahClark
New Contributor III

Thank you for the suggestion! While DaysSinceInspection is a string field, we are also using the Status field to symbolize the Temporary Removals independently but alongside the days since inspection. Filtering them would not be an ideal solution since they still need to be seen on the map by users. 

0 Kudos
jcarlson
MVP Esteemed Contributor

Makes sense! Well, in light of @RussRoberts response, I guess just changing it to "Greater than 90 days" would be the temporary workaround.

- Josh Carlson
Kendall County GIS