Select to view content in your preferred language

Append data error in Notebook

743
1
03-23-2021 06:51 AM
AFackler_NAPSG
Frequent Contributor

I am trying to do some work that appends a geodatabase that is on ArcGIS Online to an existing feature layer using the append function (as part of an archiving data effort). However, when I try to run this part of the script, it gives me the error that is seen below. The fields should match perfectly. Can I even pull in the geodatabase from ArcGIS Online or does it have to come from my local computer? If it has to come from my computer, is there a script or tool somewhere that I can download that database locally?

Thank you in advance!

AdamFackler1_0-1616507460606.png

 

0 Kudos
1 Reply
jcarlson
MVP Esteemed Contributor

Based on the error message, it looks like you're trying to run the append against the Item.

Append works against a FeatureLayer or a Table. In order to get that from your Item, you'll need to use the .layers or .tables properties.

facilityLog.layers[0].append(...)

facilityLog.tables[0].append(...)

If your service has multiple layers/tables, just be sure to use the proper index number in .layers[x].

- Josh Carlson
Kendall County GIS
0 Kudos