I have two feature classes: One contains manholes (points) and the other contains sewer mains (polyline). I need to gather the Unit ID (text field) assigned to the manhole at the start of the sewer main and place it into a field ('StartID') in the sewer main table.
I'm trying to create an attribute rule that will do such a thing. Can anyone provide some insight as I'm not having any values returned? Thanks in advance.
Here's my code:
var manholeID = FeatureSetByName($datastore, 'Exported_Manholes', ['UNITID'], true)
var start_point = Geometry($feature).paths[0][0]
if(Intersects(start_point, $feature)){
return manholeID
}
return ERROR