All,
Recently we have finished innovatory of curbed streets. The curbed streets were appended into a new feature class in batches as an area was finished. Now I am checking to make sure no street segment got appended twice. I have written/modified it the script from Delete the older records of duplicate features after using the Append tool in ArcGIS Pro, for our data.
I am encountering Error 999999. None of the advice from 999999: Something unexpected caused the tool to fail seems applicable. There is no output file, only the original input file is being modified. There is no geometry network. The used fields do not have any null values. Given where it fails in the script, size should not be an issue. Also, there are only about 9,600 records in the table currently. For testing the script, I am running this on a copy of the data set exported from the enterprise geodatabase to the project database. once the script works, it will be run on the enterprise geodatabase copy. I am unable to test it in administrator mode, but I don't see a reason why this should be an issue.
How do I get the script working, or at least get past this error? Any insight is appreciated.
Script:
import arcpy
fc = "StormCurbedStr_ExportFeature"
feilds = ["FULLNAME","curb","Shape"]
cursor = arcpy.UpdateCursor(fc, feilds)
keepList = list()
for row in cursor:
row_val_0 = row.getValue(feilds[0])
row_val_1 = row.getValue(feilds[1])
row_val_2 = row.getValue(feilds[2])
row_val = row_val_0 + row_val_1 + str(row_val_2)
if row_val not in keepList:
keepList.append(row_val)
elif row_val in keepList:
cursor.deleteRow(row)
else:
pass
print("done")
error:
RuntimeError Traceback (most recent call last)
In [5]:
Line 7: cursor = arcpy.UpdateCursor(fc, feilds)
File C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\__init__.py, in UpdateCursor:
Line 1234: return gp.updateCursor(dataset, where_clause, spatial_reference, fields, sort_fields)
File C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\geoprocessing\_base.py, in updateCursor:
Line 374: self._gp.UpdateCursor(*gp_fixargs(args, True)))
RuntimeError: ERROR 999999: Something unexpected caused the tool to fail. Contact Esri Technical Support (http://esriurl.com/support) to Report a Bug, and refer to the error help for potential solutions or workarounds
notes:
Arcpro 3.1.0
OS: Mircrosoft windows 10 pro for workstations
Thank You.
Laura