Attribute Rule Error on Published Feature Service

2647
10
01-19-2021 09:35 AM
Labels (2)
JoshHellman1
New Contributor

Hello,

I am applying the following Attribute Rule Arcade expression to a FC with a related table:

var table = FeatureSetByName($datastore,"Arrowhead_Ph2_Relocation_Table")

var total = 0

for (var t in table)

if (t.BLK_PRCL_NUM == $feature.BLK_PRCL_NUM) {

total = total + t.TOT_RELO_AMNT_OFRD

}

return total

I publish the FC and related table as a service, however, when I try to edit I get the error message below.  If I look at the attribute rules of the published service FC, I notice it changes my Arcade expression from the related table name above to an ID number.

When I test the attribute rule directly from the GDB it works perfect.

Here is the portion of the expression in the attribute rule it changes once it's published as a feature service:

var table = FeatureSetByName($datastore,"{A2D0EBF1-2A6C-4EC2-BAE3-852F03E47EBB}")

JoshHellman1_0-1611077223917.png

Why does it change my arcade expression from the Table Name I input in the expression, to the ID number? When it does this it's making the expression not find the table name in the GDB and generates this error.

Thanks!

 

10 Replies
JBeasley
New Contributor III

Figured out the source of our issue. We were referencing a table within a few rules that unbeknownst to us was updated every 3-6 months via a full replace- meaning the table was deleted a new one (of the same name) was imported. We have now advised the table be updated via a truncate/append method and have not seen the same behavior since switching. Hope this helps someone! 

0 Kudos