Select to view content in your preferred language

Arcade expression help - "no value" in related table

84
0
yesterday
KristalWalsh
Frequent Contributor

Hi all, asking for help to edit this Arcade with a related table.  I have a feature class related to a table in ArcGIS online where users will select from a list. There are 8 possible text fields to complete but often only 1 or 2 are populated. The rest should default to no value. 

Approximately 1000 data entry points have been added to date, but now we are receiving a "value should be one of the listed values" in the unused fields. I have configured a "null" value domain in Pro, set it to the default and republished. The null will default on a created record (see Fig 2) but not when attempting to edit the table in the form (see Fig 1). I don't want a user to have to click on every empty field each time there is only one species to enter.

I found this post from 2024 https://community.esri.com/t5/arcgis-online-questions/arcade-display-value-s-when-not-null-if-no-val... but I know there is more I need to do to add to account for those fields with entries.  This part of the code for my relationship class, renders it noneditable. Where do I go from here? 

//Get all related records beginning with "spp"

var related = FeatureSetByRelationshipName(
  $feature,
  "ConProjects_Poly3",
  ["spp"],
  false
);
var output = [];

for (var row in related) {
  if (!IsEmpty(row.spp)) {
    Push(output, row.spp);
  }
}
return Concatenate(output, ", ");

 

Any and all suggestions would be greatly appreciated! Thank you. 

Kristal Walsh, Florida Fish and Wildlife
Office of Conservation Planning
0 Kudos
0 Replies