Select to view content in your preferred language

append: Object reference not set to an instance of an object (code 400)

557
0
08-22-2022 01:02 PM
mikaël
Frequent Contributor

I'm trying to append a file gdb to a feature layer on arcgis online (because I want to merge them and keep the attachments and I think this is the only way).

The gdb to append is a copy of a feature layer already on agol (exported as a fgdb). The destination feature layer is also a copy of a feature layer (exported as a fgdb and then republished).

I can append the gdb through the interface successfully, however I wish to do this automatically via the REST API. I keep getting a code 400 with the message "Object reference not set to an instance of an object.".

I have read here and there that this may be a problem with null values. I also thought the problem may be that some fields have a list of required values (domain), so I deleted those and I have trimmed down the fields and rows of both tables (source and destination) to troubleshoot and I have now basically 2 small tables (of 25 and 18 rows) with only the basic rows: FID, GlobalID, CreationDate, Creator, EditDate, Editor, t_id (another ID field that references another table) and attachments.

I have tried specifying the upsert parameter to false, selecting only 1 field with fieldMappings and appendFields, but always getting the same error.


What else can I check?

Thanks!

0 Kudos
0 Replies