I am relatively new to Python, but have a workflow in which I select a group of contiguous parcels in my Parcels feature class, copy them, paste (special) them into another existing feature class called Neighborhoods and, when they are in the Neighborhoods feature class, merge them into one polygon (the neighborhood). I am trying to decide between the CopyFeatures_management and Append_management ArcPy tools for the first part, and I cannot find any ArcPy tool for the merge.
Solved! Go to Solution.
Hi
As far as I understand the workflow you should first use Dissolve without the parameter Dissolve_field (it is optional) to make one polygon in temporary fc.
Then use Append to add it to any other polygon layer.
Have fun
Here's the Merge documentation:
Merge—Data Management toolbox | ArcGIS Desktop
However, it sounds to me like you should be using Dissolve -
Thanks for your quick reply. I looked at both of those, but Merge seems to be focused on merging entire feature classes, while Dissolve requires an attribute field which, at that stage in the process, doesn't exist yet. When I perform the task manually, the tools are in the "Modify Features" tools on Pro's Edit menu, but they don't seem to have Python equivalents.
I just want to clarify your workflow so I understand what it is you're trying to accomplish.
You have a source and a target feature class. When you move the data from the source to the target, you want the data in the target to be grouped by neighborhood. Is this accurate?
Sorry, I replied via e-mail but it is not showing up here.
Yes, but by "grouped" I mean turning a set of, for example, 30 parcel polygons into one neighborhood polygon. My expectation is that I will select the parcels in Pro and then run my custom tool.
Hi
As far as I understand the workflow you should first use Dissolve without the parameter Dissolve_field (it is optional) to make one polygon in temporary fc.
Then use Append to add it to any other polygon layer.
Have fun
Thank you. I finally got it working. My script code is:
Hi
Great but you can drop the CopyFeatures Just dissolve from fc_in to fc_tempout and save a step