Hi All. I'm using the Append tool in ArcGIS Pro, and in arcpy to try and both ADD new features to a feature service in ArcGIS Online (from a feature class), as well as UPDATE existing features if they match (Upsert).
From reading the documentation here I understand that the tool should look for features with identical attributes within the fields listed under the "Update Options" section. If a feature in the Input Dataset matches a feature in the Target Dataset based on those fields, then it will update all the fields listed in the Field Map (as well as the Geometry if that option is enabled at the bottom of the pane). If no matching feature is found, then those features in the Input Dataset should be Appended as new features.
However, the behavior I'm getting doesn't seem to match that. When I have no Update fields listed, the features in my Input Dataset are being appended as New features as expected. When I do have fields listed under the Update Options section, I am seeing matching features update but new features are not being added as I would expect.
Can someone clarify if there is a problem somewhere, or if I have my understanding wrong and the Append tool is either Add or Update, not both?
Quick video showing a typical addition of new features using the Append tool (no issues).
2nd video shows the Append tool with Update Options included failing to correctly update the Geometry of a matching feature (Bowelling 3), and also adding 2 features that should not have been added (Bowelling 3 again which should have been updated and McAlinden 2 was identical so should have been skipped). It did correctly update the missing Tenure attribute against Bowelling 5.
The 3rd video showing the Append tool with Update Options included failing to correctly update the Geometry (Bowelling 3) and Attributes (Bowelling 3 & 5) of matching features, instead adding Bowelling 3 again, skipping Bowelling 5 completely but at least adding 2 features correctly.
Appends to, or optionally updates, an existing target dataset with multiple input datasets.
The opening line suggest OR, but as you point out, your clip and paragraph screengrab suggests AND
You should really contact Tech Support for clarification and to get the documentation clarified at least.
Do the target fields that aren't getting updated have the same name as the input fields?
Documentation isn't really clear, and somewhat contradicts itself, but:
You can use this tool to insert new records and update existing records in a target dataset in the same operation (equivalent to an UPSERT database operation). Use the Matching Fields for Update parameter to specify the fields from the input dataset to match to the fields in the target dataset. For records with matching field values, any fields in the target record will be updated with values from fields with the same name in the input record. Geometry will be updated if the Update Geometry parameter is checked.
This tends to suggest that it will only update fields that have the same name. Almost as if the Field Map is ignored for the upsert operation.
Have not tested, but a thought....
R_
What version of ArcGIS Pro?
Upsert was introduced in 3.1. there was a bug for this exact behaviour fixed in 3.2
So we're still on 3.1.2, so it's quite possible this is the problem, though @RhettZufelt and @DanPatterson also make good points. Looks like I'm going to have to reach out to Tech Support to get some clarification on the capabilities at least, and also find out if this bug is at play in my situation. Thanks all for you prompt feedback. Will update back here when I get an answer.
A follow-up question, in lieu if getting the update through, does anyone have a workaround suggestion? I'm happy to work in python as thats where the final process will actually be executed from. I resorted to Pro to help write and test arcpy steps in my process. So I'm not bound by ArcGIS Pro, or arcpy. Those are just what I'm most familiar with and I had no luck with Copilot and testing alternative methods.
Nothing gets fixed unless it gets reported.
Also, there is a link on the help topic page that you can supply comments for the help topic.
I find regularly that any lack of clarity in a help topic is address by correcting an error, or by that team contacting the appropriate section within esri to confirm what is written.
Could just be me, but it would be worth reporting, especially since beta 3.4 will be coming up
The exact issue that Lindsay is describing was reported as a defect in 3.1 and fixed in 3.2.
Lindsay is on 3.1.
There's no benefit to reporting it as they will ask you to update and test the issue on the version where the issue has been fixed. May as well do that first.
I'm also not seeing any issues with the documentation, it seems like the user hit a known defect.