<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Append reports success, but no rows appended to hosted feature service. in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1633615#M11506</link>
    <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/417766"&gt;@Clubdebambos&lt;/a&gt;&amp;nbsp;Sorry for the late reply!&amp;nbsp; For some reason I don't get email notifications when my questions are responded to.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;P&gt;The way I always think about it is that the append doesn't take data from disk, it takes data from an ArcGIS Online/Portal Item. Your gdb needs to be hosted in Portal/AGOL (or your GeoJSON).&amp;nbsp;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Yeah, I finally bumped up against that.&amp;nbsp; I don't know what to say.&amp;nbsp; It's not a good workflow.&amp;nbsp; I should not have to do I/O in order to take content and append it to the service.&amp;nbsp; I should be able to put it in a compatible dataframe and just rock and roll.&lt;/P&gt;&lt;P&gt;I ended up just moving to an enterprise geodatabase in the end, as I can just use a referenced service and update the table, without ever messing with the Portal API.&lt;/P&gt;</description>
    <pubDate>Wed, 16 Jul 2025 18:57:21 GMT</pubDate>
    <dc:creator>EricEagle</dc:creator>
    <dc:date>2025-07-16T18:57:21Z</dc:date>
    <item>
      <title>Append reports success, but no rows appended to hosted feature service.</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1622683#M11446</link>
      <description>&lt;P&gt;I'm attempting to test some access controls on an ArcGIS Enterprise instance by running a simple script that appends rows from a feature class into a hosted feature service.&lt;/P&gt;&lt;P&gt;In order to ensure schema match, I took one feature class, and published it as a hosted feature service.&amp;nbsp; Then I selected 4 or 5 rows from that same feature class, exported them to a new feature class, changed some things around in the attributes, saved, and then attempted to append those rows.&amp;nbsp; I am not receiving any error from the following code, but none of the rows are updating the hosted feature service.&lt;/P&gt;&lt;LI-CODE lang="python"&gt;from arcgis import GIS
import arcpy
import os

url = 'url to my ArcGIS Enterprise instance'
username = 'my username'
pw = 'my pw'
gis = GIS(
    url=url,
    username=username,
    password=pw,
    verify_cert=False)

target_layer = gis.content.get('layer id').layers[0]
print(target_layer) #succeeds

#Data I need to append to the feature service layer
fgdb = 'path/to/fgdb.gdb'
append_layer = os.path.join(fgdb, 'append_features')

target_layer.append(append_layer)
print('Local layer appended to service successfully.')&lt;/LI-CODE&gt;&lt;P&gt;Again, no errors, but nothing committed.&lt;/P&gt;&lt;P&gt;I read into the docs and it seems like I may not be able to append a feature class to the feature service directly - that is fine, I just ran a simple conversion to GeoJSON, editing lines 18-22 like so:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;fgdb = 'path/to/fgdb.gdb'
append_layer = os.path.join(fgdb, 'append_features')
outfile = 'path/to/outfile.geojson'
append_feats = arcpy.conversion.FeaturesToJSON(append_layer, outfile, geoJSON='GEOJSON')

target_layer.append(append_feats)&lt;/LI-CODE&gt;&lt;P&gt;This also succeeded in creating the .geojson file, and returned no errors, but again, no rows were actually committed to the target service layer.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;What am I doing wrong, and how do I ensure a meaningful error is reported when a hosted feature layer's .append() action fails?&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Jun 2025 15:46:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1622683#M11446</guid>
      <dc:creator>EricEagle</dc:creator>
      <dc:date>2025-06-11T15:46:17Z</dc:date>
    </item>
    <item>
      <title>Re: Append reports success, but no rows appended to hosted feature service.</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1623786#M11450</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/171761"&gt;@EricEagle&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;A couple of things here. The first is to check the documentation for &lt;A href="https://developers.arcgis.com/python/latest/api-reference/arcgis.features.toc.html#arcgis.features.FeatureLayer.append" target="_blank" rel="noopener"&gt;append()&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The way I always think about it is that the append doesn't take data from disk, it takes data from an ArcGIS Online/Portal Item. Your gdb needs to be hosted in Portal/AGOL (or your GeoJSON).&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you simply print(target_layer.append(append_layer)) you will get True or False returned. Many of the ArcGIS API for Python methods fail gracefully in that it will give you more details about what us unsuccessful/successful but won't error and exit the script.&lt;/P&gt;&lt;P&gt;Your script should look something more like the below...&lt;/P&gt;&lt;LI-CODE lang="python"&gt;target_layer.append(
    item_id ="THE_ID_OF_THE_HOSTED_ZIPPED_GDB",
    upload_format = "filegdb",
    source_table_name = "THE_NAME_OF_FC_IN_THE_GDB",
    field_mappings = DICTIONARY - SEE DOCS IF NEEDED
)&lt;/LI-CODE&gt;&lt;P&gt;The append can be very finicky and detrimental to your mental health so take deep breaths. You also have other options. You can use ArcPy and the &lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/append.htm" target="_blank" rel="noopener"&gt;Append()&lt;/A&gt; geoprocessing tool.&lt;/P&gt;&lt;LI-CODE lang="python"&gt;arcpy.management.Append(
    inputs = "PATH_TO_FEATURE_CLASS",
    target = "FEATURE_LAYER_URL",
    schema_type = "NO_TEST", (will only match up if field names are teh same - see docs)
    feature_service_mode = "USE_FEATURE_SERVICE_MODE" (optimisation available with ArcGIS Pro 3.5+)
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;Let us know if any of this helps or if you need any further guidance just let me know.&lt;/P&gt;&lt;P&gt;All the best,&lt;/P&gt;&lt;P&gt;Glen&lt;/P&gt;</description>
      <pubDate>Mon, 16 Jun 2025 08:34:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1623786#M11450</guid>
      <dc:creator>Clubdebambos</dc:creator>
      <dc:date>2025-06-16T08:34:49Z</dc:date>
    </item>
    <item>
      <title>Re: Append reports success, but no rows appended to hosted feature service.</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1633615#M11506</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/417766"&gt;@Clubdebambos&lt;/a&gt;&amp;nbsp;Sorry for the late reply!&amp;nbsp; For some reason I don't get email notifications when my questions are responded to.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;P&gt;The way I always think about it is that the append doesn't take data from disk, it takes data from an ArcGIS Online/Portal Item. Your gdb needs to be hosted in Portal/AGOL (or your GeoJSON).&amp;nbsp;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Yeah, I finally bumped up against that.&amp;nbsp; I don't know what to say.&amp;nbsp; It's not a good workflow.&amp;nbsp; I should not have to do I/O in order to take content and append it to the service.&amp;nbsp; I should be able to put it in a compatible dataframe and just rock and roll.&lt;/P&gt;&lt;P&gt;I ended up just moving to an enterprise geodatabase in the end, as I can just use a referenced service and update the table, without ever messing with the Portal API.&lt;/P&gt;</description>
      <pubDate>Wed, 16 Jul 2025 18:57:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/append-reports-success-but-no-rows-appended-to/m-p/1633615#M11506</guid>
      <dc:creator>EricEagle</dc:creator>
      <dc:date>2025-07-16T18:57:21Z</dc:date>
    </item>
  </channel>
</rss>

