Hi super smart Esri Community,
I am seeking a solution to delete rows in a hosted table through python script in a notebook on AGOL. I can't use any solution that touches a local file like a csv file.
The chunk before this need is:
# delete features with where avg_ is less than 2
Carc.delete_features(where="avg_ < 2")
# where Carc =
The need is something that will delete all rows from this table if three distinct fields within Carc repeat.
For example, in the picture below, the solution would leave each row in the table with a unique set of 3 values in the fields sensor_id, time_stamp, and avg_. So, in the picture below, the solution would leave the 2 first rows and remove 2 of 4 of the last 4 rows, because they have non-unique sets of sensor_id, time_stamp, and avg_.
Best,
Eli L
Solved! Go to Solution.
I haven't tested this so you may have to mess with it a bit but I believe the logic is solid
Can you use DeleteIdentical()?
Delete Identical (Data Management)—ArcGIS Pro | Documentation
Thank you, Alfred. I don't normally use the advanced runtime required for arcpy, yet it is a simple, good solution and I appreciate your time and help.
I haven't tested this so you may have to mess with it a bit but I believe the logic is solid
Thank you, Kelly. That works great!