Symbolize Feature Service on Two Fields in Web Map

1355
5
06-14-2021 08:37 AM
MichaelVolz
Esteemed Contributor

I am trying to symbolize a feature service on two different fields in a Portal web map.  The first field I choose I have all fields available.  Unfortunately, the second field I try to choose only appears to be numeric values (field list is filtered outside my control) and I want the second field to be a string field, so I am unable to symbolize the layer like I can in ArcMap or Pro.

Has anyone ever encountered this limitation?

Any ideas on how to overcome this problem if I do not have Ownership of the data and I am required to use the data as is?

0 Kudos
5 Replies
DavidPike
MVP Frequent Contributor

If you go to symbology are you able to add 'new expression'? If so, it should just be a case of entering an expression of Text(yourNumberField). 

0 Kudos
MichaelVolz
Esteemed Contributor

Thanks David.

That looks like the path I will go down and I have had some success.

I am somewhat puzzled as I am unable to get one of the unique values symbolized in AGOL even though I can see the unique value symbology in Pro with the same feature service.  Are there any limitations on the values that are recognized in an Arcade expression?

0 Kudos
DavidPike
MVP Frequent Contributor

A lot of the symbology options will be less refined than in desktop.  I'm not sure what you mean in your last sentence, but I don't think the issue is with any arcade expression, more the rendering options available.

For example, only 200 unique values can be categorised in AGOL (both in classic and map viewer) with only 10 colours available. Style categories (Map Viewer Classic)—ArcGIS Online Help | Documentation

0 Kudos
MichaelVolz
Esteemed Contributor

So I am only trying to use 5 different unique value combinations between two fields so I am no where near the 200 unique value limit.

0 Kudos
GGrossiCarrollton
New Contributor
As usual, I tried making things more complicated than they needed to be by using IF/AND/THEN/ELSE expressions for every possible combination. All it needed was to return one thing.

Symbolize -> Custom Expression>
 
var VALA= $feature.A;
var VALB = $feature.B;
 
return VALA +"-"+VALB;
 
Select Drawing Style -> Unique Symbols
 
All the possible combinations (up to 200) should show up.
 
Tested and verified.
0 Kudos