Hi @surbhi,
Thanks for your question. It looks like a similar, but slightly different issue was reported here:
https://knowledge.safe.com/questions/37710/cant-write-values-to-arcgis-online-feature-service.html. I'm wondering - what version of FME are you running currently? Might be worth downloading and trying the
latest official release to see if it's an issue that has been fixed, if not already using it.
Thanks,
Nathan
Hi @surbhi,
Thanks for your question. It looks like a similar, but slightly different issue was reported here:
https://knowledge.safe.com/questions/37710/cant-write-values-to-arcgis-online-feature-service.html. I'm wondering - what version of FME are you running currently? Might be worth downloading and trying the
latest official release to see if it's an issue that has been fixed, if not already using it.
Thanks,
Nathan
Hi Nathan,
thanks for replying! I am trying to stay at the same version as the organizational FME server, does that matter? I am using 20170929 - Build 17650 - WIN32
For other users who may run into this issue, please feel free to open a support ticket
here as we are investigating this issue internally and do not yet have a solution. It does, however, seem that this error might arise from the following situations:
1) The length/size of an attribute is too long for ArcGISOnline to handle, so it tries to truncate but fails.
2) The datatype of an attribute mismatches the ArcGISOnline datatype.
Take care to optimize your attributes to prevent these issues and you may avoid the error.
Thanks for your patience with the issue.
Best,
Nathan
Nathan, you are right. I had to truncate one of the fields to 300 and then feature service publication worked.
thanks!
Nathan, you are right. I had to truncate one of the fields to 300 and then feature service publication worked.
thanks!
Nice! Glad you've got it working.
For other users who may run into this issue, please feel free to open a support ticket
here as we are investigating this issue internally and do not yet have a solution. It does, however, seem that this error might arise from the following situations:
1) The length/size of an attribute is too long for ArcGISOnline to handle, so it tries to truncate but fails.
2) The datatype of an attribute mismatches the ArcGISOnline datatype.
Take care to optimize your attributes to prevent these issues and you may avoid the error.
Thanks for your patience with the issue.
Best,
Nathan
I get the following error when trying to insert new records into an existing service (updates and deletes work correctly).
The error code from the server was '1000' and the message was: 'Object reference not set to an instance of an object.'
Doesn't seem to be the length/size or data type either, so have raised a support ticket as suggested.
Thanks
I've been having similar problems while trying to update the ArcGIS Online Feature Services. I get the same error message as surbhi, but the solution that worked for him didn't solve my issue. It just added a another error message:
” ArcGIS
Online Feature Service Writer: Attribute 'X' on feature type 'layer_name' has
width 400, but the width on the server is 200”
Data types and lenghts/sizes of attributes should be the same as with the layer already in ArcGIS Online. I'm using 2018.1 version of FME. Any other workarounds come to mind?
Interesting error for sure.
Similar issue here but it sometimes works, sometimes not. AGOL truncated a field to the set 256 successfully yesterday but failed today. I find AGOL a little inconsistent but good to know this fixed it.
Thanks!
I have had similar issues with hosted Feature Layers in ArcGIS Online.
Two things helped me solve my problems.
- Create the ArcGIS Online hosted Feature Layers in ArcGIS Online by importing a zipped File Geodatabase instead of creating them directly with FME.
- Make sure all the text attributes are at least 255 characters long.
The workflow I used:
Create the workspace you want for updating the ArcGIS Online Feature Layer. Add a File Geodatabase Writer to the workspace instead of ArcGIS Online Feature Service Writer. Make sure no text attributes are shorter than 255 characters. Zip the created File Geodatabase and import it to ArcGIS Online to create the hosted Feature Layer.
Go back to the FME Workspace (delete/disable the File Geodatabase writer) and add the ArcGIS Online Feature Service writer and choose to import the layer definition from the Feature Layer.
My feature types are set to; Writer mode: Insert & Truncate First: Yes
I have not had any problems updating the Feature Layer since implementing this workflow.
FME Desktop 2019.0 Build 19238 - WIN64
It took me a while to find this workaround for all issues related to writing to AGOL with FME. Bin it and upload the data manually.
I have been having the same issues.
My workaround is to try and publish the AGOL data but change the "Feature per request" to 1. You can then see which row the data is failing and inspect your data before the writer to figure out which attribute is exceeding the character limit. Once you identify the attribute which is exceeding this limit, go to your AGOL item page on the data tab and delete that attribute (as long as you don't mind losing this data). After deleting the attribute, recreate it on the same page with a higher character limit, then you'll be able to publish from FME. Make sure to update the character length in your FME writer after changing it in AGOL.
For other users who may run into this issue, please feel free to open a support ticket
here as we are investigating this issue internally and do not yet have a solution. It does, however, seem that this error might arise from the following situations:
1) The length/size of an attribute is too long for ArcGISOnline to handle, so it tries to truncate but fails.
2) The datatype of an attribute mismatches the ArcGISOnline datatype.
Take care to optimize your attributes to prevent these issues and you may avoid the error.
Thanks for your patience with the issue.
Best,
Nathan
Hi Nathan,
Has there been any update in understanding the cause of this issue? I have a similar issue but my error reads "...the error code from the server was '1000' and the message was: 'Conversion failed when converting date and/or time from character string.'
It's difficult to make out what the issue is. My fields are not mismatched. However in AGOL, they are set to 200 so I will try the suggestion that @frro mentioned below (though this is very challenging in and of itself).
Thank you
Hi Nathan,
Has there been any update in understanding the cause of this issue? I have a similar issue but my error reads "...the error code from the server was '1000' and the message was: 'Conversion failed when converting date and/or time from character string.'
It's difficult to make out what the issue is. My fields are not mismatched. However in AGOL, they are set to 200 so I will try the suggestion that @frro mentioned below (though this is very challenging in and of itself).
Thank you
Hello @jdiggity , If its set to 200, I don't think its the truncation issue, but it does look like a data error. I would check to make sure you're writing your datetime attributes as datetime type in your AGOL Writer (Check 'User Attributes'). It looks like AGOL expects datetimes to be written in a certain syntax (MM/DD/YYYY hhss - Linked this here incase you wanted more infromation). Let me know if this helps or if you're still having issues! Kailin.
Hi Nathan,
Has there been any update in understanding the cause of this issue? I have a similar issue but my error reads "...the error code from the server was '1000' and the message was: 'Conversion failed when converting date and/or time from character string.'
It's difficult to make out what the issue is. My fields are not mismatched. However in AGOL, they are set to 200 so I will try the suggestion that @frro mentioned below (though this is very challenging in and of itself).
Thank you
Hi Kailin, thank you very much for the response. I did as you suggested and forced the date values from the reader through a DateTimeConverter using the AGOL syntax you referenced and it worked! Much appreciated.