I thought I had seen this question somewhere before but now I can't find it (neither an answer)...
After the upload of a survey failed with the error "code 1003, Operation rolled back", is there any other option to download the data somehow from the device?
For the error itself I have this thread: https://community.esri.com/message/638532-error-code-1003
THis just saved my @$$... thank you Seth Paine!
As an FYI - tried setting this up as a script in Pro, but it didn't seem to want to run it. I simply manually entered the parameters in PyScripter and ran it there.
inDB = 'C:/Users/YOU/.../ArcGIS/My Surveys/Databases/a084e6XXXXXXXXe8ec667ca329a63.sqlite' gdb = 'C:/Users/YOU/AppData/Local/Temp/ArcGISPro4804/afdf1967-XXXXXXXX6139267/Default.gdb'
One downside is that dates get cast back to strings, meaning a lot of manual conversion.
James Tedrick I had to do this as the original completed survey was giving me the #string truncated error. I've since modified my survey to ensure all field lengths are sufficiently long. My plan was to restore the DB and simply republish the troublesome surveys sitting in my OutBox. However it's still giving me the #string truncated error. Bizarrely, I manually recreated the results (minus the photos and location info) and it submitted fine. Can I ask for your advice on how/if I will ever be able to get the surveys sat in my outbox published without having to manually recreate them and thus lose the photos and location info?
I created a script to export a Survey123 SQLite database into file geodatabase feature classes:
arcpy - Importing Survey123 SQLite Database from Device - Geographic Information Systems Stack Exchange
The send error give the additional text:
"Incompatible feature service. Parent to child relationship not found from TCEF_Fire_History (0) to plotRepeat(3)"
Hi Karissa,
Is there additional error text? It sounds like there is a configuration issue between the feature service and the survey. The recovery procedure is the workflow you attempted via the tablet (the Survey123 app, not Survey123 Connect).
I have been trying to work through the same troubleshoot you did, but with no success. My error is 202. I have been able to work through the recover data from the mobile device down to replacing the path names using DB Browser. From there I have no luck. I have opened the Survey123 Connect on my desktop and I cannot find a place to navigate to these files to upload my data from the desktop. If I work from the Survey123 on my tablet I am having the same error and I cannot resend the surveys. And I don't see an obvious way to upload that .sql file with the changed path to Survey123 online. So I think I am missing a critical step. Any thoughts on what I might be missing?
That is fantastic, thanks for that Nicole!
At least we know that it can be done now, and we should be able to work something out. I am thinking about building a python too that can do the copy automatically for the user.
Hi Dan,
I think it's in fact a good strategy to back up the sqlite database in the field instead of uploading it straight away. The way it is described here Troubleshoot—Survey123 for ArcGIS | ArcGIS should work for you.
I have a similar question, although we are interested in being able to do a backup of the survey data for teams that are in the field without cellular data connectivity for long periods of time (common in Australia!). I will look into this further and see if the process for recovering data from the mobile device could be followed to make backups.
After changing my search to something similar to "survey123 export from sqlite" I found this post for troubleshooting Survey123:
Troubleshoot—Survey123 for ArcGIS | ArcGIS
The last topic deals with how to recover data from a mobile device.
I tested it with my own copy of the survey, not the original one that my client was using. I adjusted the path to the survey in the database with the sqlite database browser matching the path that was created when I filled a survey on my desktop. Then my survey showed me the four surveys that were not uploaded.
After removing some of the constraints in the survey I opened the failed surveys, saved them without changing anything and was able to upload them. I only had the impression that one value got lost in a repeated field (which is bad enough).
Maybe this helps someone having similar issues. I still can't really tell, what caused the Error Code 1003 but at least the data is online now. It might have been something to do with those constraints.
(no answer from Ismael yet)
Hi Zoltan,
I didn't get the idea that I could open the sqlite database straight in ArcGIS 🙂 Thanks for that.
I think I will contact Ismael directly to see if he has something in his pockets to help me.
Ah, shoot... I thought the same runtime gdb format was being used, but clearly it's not the case - I just had a quick look now. Sorry, I was wrong about the extraction part. On the other hand, you can open the SQLite database directly in ArcGIS (used 10.3.1), but it does not give you any friendly data as everything is stored as it would be sent to the service holding the FS (and you would need to filter for the survey in question as it's being used for all surveys with unsent data)...
It might be best to ask Ismael in case they have some workaround or tool to extract/submit the data easily. You may be able to construct a JSON out of the .sqlite content and use the REST API to send the data in, but I haven't done anything like that yet...
Sorry I couldn't have been of more help this time.
I was able to copy a database abc.sqlite from the tablet and could access the data somehow but the way it is stored will be a bit tricky to have it exported into a gdb. Unfortunately the tool you mentioned is not working for sqlite databases as it seems.
Hi Nicole,
When connected to the device from your computer (or with a suitable app on the device), you can simply copy the ArcGIS folder to have a backup. The data is organised into My Surveys and My Survey Attachments folders (at least on Android, iOS should be similar).
It might be a bit tricky to find a particular survey as they are referenced by the Form ID stored in AGOL (so not with the name you gave to your survey). You can find this out if you go to the Form in question in AGOL, click on View Item details and have a look at the URL in the address bar. The part after 'id=' will be the same id used to store the survey on the device.
You can try to recover the data from the runtime database(s), have a look at the below tool available in ArcGIS (10.3+).
https://desktop.arcgis.com/en/arcmap/10.3/tools/conversion-toolbox/copy-runtime-geodatabase-to-file-geodatabase.htm
I hope this helps.
Les membres connectés peuvent publier, suivre les mises à jour, et plus encore. Nouveau ici ? Inscrivez-vous gratuitement.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.