Hello all- I am working to set up our attribute rules. I would like to create a rule that will copy edited row of a feature class to another feature class when there is a status change from Attribute values. am following this error based on code provided in the forum: EW is relationshipclass maintaining parent GLOBALID(as CGUID) and comparing anc evaluating new lstatus
var globalId = $feature.globalid
var lstatus = $feature.LSTATUS;
var tableToUpdate = "EW";
var returnField1 = "GLOBALID";
var returnField2 = "globalid"
var fs = FeatureSetByName($datastore, "EW", [returnField1, returnField2], false);
var feats = Filter(fs,'CGUID = @globalId');
if(feats == null || Count(feats) == 0) {
return $feature.comments;
}
else{
for(var feat in feats){
var updateDict = {'GlobalID': feat.globalid, 'attributes': {}};
updateDict['attributes'] ['lstatus'] = lstatus;
var updateList = [updateDict];
var editDict = {'className': tableToUpdate, 'updates': updateList};
var editList = [editDict];
var returnDict = {'edit': editList};
return returnDict;
}
}
return $feature.comments;
I am getting an error "
Update table row : EL
update table row failed.
A requested row object could not be located.
Rule Name : AR23
Triggering Event Update
ClassName: EL,
GlobalID :{xyz--xyz}"