Hello,
I'm working on a polygon layer consist of more than 1000 polygons. I want to export each single polygon
as a new polygon layer. Is there a simple way to perform this task ? Thank you.
Solved! Go to Solution.
If it was a shapefile, you could use http://www.arcgis.com/home/item.html?id=15ca63aebb4647a4b07bc94f3d051da5 using the FID (or objectid) field. It isn't setup to work with featureclasses for a variety of reasons, hence, the extra step to export to a shapefile first
If it was a shapefile, you could use http://www.arcgis.com/home/item.html?id=15ca63aebb4647a4b07bc94f3d051da5 using the FID (or objectid) field. It isn't setup to work with featureclasses for a variety of reasons, hence, the extra step to export to a shapefile first
The link seems to be broken, can you post the answer again, please?
I think Dan Patterson made a tool to do this (SplitFeatureClassByAttribute, or similar). Oh, he beat me to it.
Or, you could make a ModelBuilder model using Iterate Feature Selection, followed by Copy Features.
Or, if you prefer a Python answer, let me know.
Hi Darren,
Could you please share the python answer with me ?
The toolbox I reference has python scripts that you can use, if you want to edit it for your case.
>>> fc = 'all_aoi' # path to feature class or name of layer in map ... arcpy.env.workspace = r'in_memory' # default folder ... OID_field = arcpy.Describe(fc).OIDFieldName # get OID/FID field name ... with arcpy.da.SearchCursor(fc,OID_field) as cursor: # create cursor ... for row in cursor: # loop through features ... where = '{0} = {1}'.format(arcpy.AddFieldDelimiters(fc,OID_field),row[0]) # set up where clause ... arcpy.SelectLayerByAttribute_management(fc,"NEW_SELECTION",where) # select the current feature ... arcpy.CopyFeatures_management(fc,'Output_' + str(row[0])) # output feature to new feature class
Hi
Thank you for your great help.