AnsweredAssumed Answered

Python Object Error on Zonal Statistics For Loop

Question asked by JohnWallX on Sep 1, 2016
Latest reply on Sep 2, 2016 by JohnWallX

I have a feature class containing multiple buffers. I would like to iterate over those buffers and perform Zonal Statistics identifying the minimum. But, I keep getting an RuntimeError: Object: Error in executing tool and I can't for the life of me figure out what I'm doing wrong.


#Inputs & Outputs
useMultiBuffs = "C:/gis/data/xy/hydropath.gdb/useErased"
gdbName = "scratch.gdb"
filepath = "C:/gis/data/xy"
DEM = "C:/gis/data/raster/dem1m"
allMinPnts = "C:/gis/data/scratch.gdb/allminpnts"
buffIntersects = "C:/gis/data/xy/hydropath.gdb/buffIntersect15m"

#Workspace, Extensions & Environment Variables
arcpy.CheckOutExtension("Spatial") #Checkout Spatial Extention


field = "OBJECTID_1"
callField = '"%s"' % field
cursor = arcpy.SearchCursor(useMultiBuffs)
row =
while row:
outZonalStats = ZonalStatistics(row, callField, DEM, "MINIMUM", "NODATA")
buildOutName = filepath + "/" + gdbName + "/" + "z" + row.getValue(field) + "r"
row =


print "DONE!"