AnsweredAssumed Answered

Merging features in feature class with arcpy

Question asked by tab5ay_uvalibrary on Sep 18, 2019
Latest reply on Sep 20, 2019 by jmoore3274

I need to merge all polygon features in a given feature class into a single polygon. The intended functionality is similar to the "Merge" tool under the Edit->Tools tab. The Merge_management tool takes feature classes as an input and I cannot find documentation on the difference/command for this "Edit->Merge." 

 

I figure I will have to iterate through my feature class using a search cursor and use the dissolve tool to merge the features. I have tried iterations of the following to no avail:

with ap.da.SearchCursor(feature_class, "*") as cursor:
    feature_list = []
    for row in cursor:
        feature_list.append(row)
    ap.Dissolve_management(feature_list, out_feature_class, {dissolve_field},{statistics_fields}, {multi_part}, {unsplit_lines})

My question is what do I use as my in_features (first field in ap.Dissolve_management)? How do I pass the features into the ap.Dissolve_management function?

Outcomes