I just used the Overwrite Web Layer in ArcGIS Pro to update a Hosted Feature Layer in ArcGIS Online. That Hosted Feature Layer updated successfully, however, the Hosted Feature Layer View that we have in a lot of ArcGIS Online maps/apps did not update. An error message pops up saying that the layer is not available anymore.
I did this successfully back in September 2022, but it is not working right now. Does anybody know what may be happening here? Did ESRI change this capability? Any comments are appreciated.
Thanks!
Are the attachments coming from the source dataset, or are you trying to maintain things that have been attached to the destination?
I don't have an "overwrite" process that involves layers with attachments, but I do have a few layers with attachments that get updated from an external source. It's a different process, using the pandas module's compare method to identify edited rows between source and destination, then updating those features in place.
More complex to set up, but say you have a 50k feature layer and only 1000 actually get edited in the source, this would only edit those 1000 in the destination, leaving the other 49k untouched entirely. It's equivalent to just opening the attribute table and making edits, albeit much, much faster.
If you're interested, I presented on the topic at a conference last year, and you can find all the notes and Python code here: https://github.com/jdcarls2/ilgisa-2022/blob/main/hosted-copy/hosted-copy.ipynb
Looking for a way to "Overwrite" my hosted layer with local (SDE) data.
The data is a combination of local data and hosted data, but I bring them all together in a local feature class, edit/modify, etc.
Then, I want to overwrite the hosted feature layer with the "new" data. If I don't make any schema changes, ensure layer id's dont change, etc. "most" of the time, I can overwrite the HFL with Pro, and it works just fine. However, as we all know, now and then, it will 'break' pretty much everything that is tied to it, and it all needs to be re-configured.
Trying to avoid this, and have had good success with truncating the HFL data and appending the SDE data to it. This works well, even maintains the attachments. HOWEVER, the Preserve Global IDs does NOT work with HFL. Documentation says it's a "known limitation" which past experience tells me that most likely ESRI does not plan on changing this.
Basically, trying to figure out a way to 'replace' a HFL's data without breaking any maps/popups/apps/etc. that are using it, but, need to maintain the attachments and the Global ID's, but am not able to figure out a tool/method that does both.
Interesting that I can go from HFL to SDE/MGDB with no issues, but can't go the other way.
Kind of defeats the purpose of a unique global id if it is changing on you......
Thanks again for any insight,
R_
We are doing the same thing as @RhettZufelt , and get some interesting issues, have lots of retries built in to get it to work. Will ping colleagues to post some help as we figure things out.
Hi Everyone, I wanted to follow up on this thread because I have the same problem, but the hosted feature service is published by another organization, so I have no control over how they do their updates. Is there anyway to actually repair broken layers after an update?