I am trying to update feature layers used in web maps on ArcGIS Enterprise with ArcGIS API for Python. I can have access to their feature sets by the code. I am using the sample of "Updating Features in a Feature Layer". The sample uses csv file to update the feature layer. Are there any possibilities to use spatial view of SQL Server to update feature layers? I converted the spatial view to a query layer and then converted it to a feature class, but I could not use the feature class for merging. I received the following error message:
can not merge DataFrame with instance of type <class 'arcpy.arcobjects.arcobjects.Result'
Please help me for this case.
Thanks for sharing the tool. I really appreciate it. I am trying to run the tool, it is failed. It looks like the URL of the feature service is not correct.
The URL I am using for the tool is similar to the following.
Can you share the service to a Group in ArcGIS Online and invite my user account (jskinner_CountySandbox)? I'll download a copy, re-upload, and then try executing the tool.
You won't need to create a user account for me. You can invite my user account that already exist. Within an ArcGIS Online Group click invite user and uncheck Only search for members in. Search for jskinner_CountySandbox and send the invite to that account.
I was able to get this to work. Here are the steps I took in ArcGIS Pro after I downloaded the service as a feature class:
1. Published the feature class to ArcGIS Online
2. Exported a selection out of the feature class
3. Updated the Design Elevation for the export to 10
4. Executed the tool using the ElementNumber field as the unique identifier:
The service updated successfully with the new features who have a Design Elevation of 10.
Thanks for sending the result. I believe that the tool is working well. It seems that there is an issue on my end. I created a new feature class and divided it in two parts. So, the second part is appended to the first part by the tool. I published the first part as "Hosted Feature Layer" on both ArcGIS Online and Enterprise. I executed the tool, but I received two different error messages.
For ArcGIS Online, it looks that everything is working well, but no new row is appended to the hosted feature layer. I checked the tool twice. One time with defining a field value and the other time with no field value. Both had the following error.
This is the error message.
For ArcGIS Enterprise, there is a problem in connection.
It is "ConnectionError: HTTPSConnectionPool(host=' ', port=7443): Max retries with url: /arcgis/sharing/rest/generateToken