Point in Polygon

156
3
03-20-2020 03:00 AM
LukasWingert
New Contributor II

Hi,

i got two Feature Layers in my ArcGIS Online Subscription. One Layer got Point geometries and will grow constantly and the other one depends on static Polygon geometries. The point geometries should be expanded with attributes of the geometry layer if the point is in a specific geometry. I could use the join_features function but my script should run periodically and should only go through the newly added features. Is there a way to do that?

Tags (1)
0 Kudos
3 Replies
DavidPike
MVP Frequent Contributor

a spatial relate would be nice, someone please make that btw

Maybe your script could select only new features to run the join on, i.e hold a text file somewhere which references the most recent object id, select those greater than it then run the join and replace the oid in the text file.

0 Kudos
LukasWingert
New Contributor II

is there a possibility to run a spatial join on a selection of features of a feature layer? I am able to get the newly added points by querying the feature layer but i cant find a way to do the spatial join on that FeatureSet.

Why i do this: I am using Survey123 which generates a feature layer of point geometries. Unfortunately the postal code is missing, so i try to add this attribute by doing the spatial join. After the postal code is added to the points i want to export all points to a csv file. Therefore i want to create a script that will run periodically.

1. add postal code to point features

2. download as csv

0 Kudos
JakeSkinner
Esri Esteemed Contributor

Hey Lukas,

Would using Arcade resolve this issue for you?  See the following blog:

https://community.esri.com/community/gis/web-gis/arcgisonline/blog/2018/12/10/overlapping-features-i... 

If not, I would approach this using GP tools in ArcGIS Pro.  They can be used on feature services just as if they were feature classes.  I would add a Date field to the point feature service, and update this with the current date when the join is executed.  For each iteration, you could then filter out only the features that have a NULL date and perform the join operation.  Once the script is complete, you can use a scheduled task to run the script.

0 Kudos