I'm using a Search cursor to Print all the unique Serial Numbers from the attribute tool.
lyr = "Tracks"
serial = arcpy.da.SearchCursor(lyr, ['CL'])
unique_CLs = list(set([row[0] for row in serial]))
unique_CLs
print(unique_CLs)
It'll then print all unique serial numbers [1], [2], [3], [4], [5] etc.
How would I then script Select by attribute, create layer for each individual serial number?
Solved! Go to Solution.
You would skip reinventing what already exists
Split By Attributes (Analysis)—ArcGIS Pro | Documentation
If you need to script, pass the parameters to the tool in your script
You would skip reinventing what already exists
Split By Attributes (Analysis)—ArcGIS Pro | Documentation
If you need to script, pass the parameters to the tool in your script
Thanks!