As part of a workflow in an python toolbox, I need to grab a table created from a layer in ArcGIS Pro. I've tried several methods, but they all take an absurdly long time. For a table with 50,000 records and <10 columns (weighing in at ~10 MB on disk), it takes well over 3 minutes. I can't expect a user to wait >3 minutes for a tool to run, so I'm trying to see if there's a more efficient method. Here's what I've tried:
tmp=arcpy.da.TableToNumPyArray("temp") # 3 mins 22 seconds
arcpy.conversion.ExportTable("temp", my_dir) # 3 mins 31 seconds
l=[]
with arcpy.da.SearchCursor('temp', field_names) as cursor:
for row in cursor:
l.append(row) # 3 mins 25 seconds
Is there really no way to get a small file in less than 3 minutes?