I am looking for Rules that will help Move Surveys from ArcGIS Online to out Enterprise Portal.
Any guidance will be appreciated.
How were the surveys created? In Connect or Web Designer?
Do you have existing production data in the feature service? Are you wanting to move the feature service as well as the survey Form item?
Thanks for your time to respond.
The survey was created using excel in connect. I have existing test data in the feature service not production so a new feature service can be created and I can reconfigure the layer as necessary.
Yes, in that case the best option is to create a new FS and Survey in the new Portal, and not try to copy/migrate the currently published one over as there are a few limitations and workarounds that take longer than trying to create new again.
The original question is over a year old so I wanted to know if there were any updates on moving existing surveys created in both Web and Connect, with and without feature services, from Online to Portal.
Hello Audrey Edwards,
The ArcGIS API for Python has a function called `clone_items` within the content manager. This function can be used to move existing surveys created in both the Web Designer and ArcGIS Survey123 Connect.
Please use this link for more information on using the `clone_items` function: Cloning Content | ArcGIS for Developers
We are working on creating some samples that showcase this workflow with the goal of writing a blog on the workflow.
I have attached two samples that we have so far to clone content from either ArcGIS Online to ArcGIS Online, ArcGIS Online to ArcGIS Enterprise, ArcGIS Enterprise to ArcGIS Enterprise, or ArcGIS Enterprise to ArcGIS Online.
Please note these scripts are a work in progress and it is highly highly recommended to save your survey as a new survey and test the script against the test survey to confirm everything functions as expected. I have tested both using ArcGIS Online to ArcGIS Online and ArcGIS Online to ArcGIS Enterprise using a survey published from both the Web and Connect, but not the rest of the Portal scenarios and not with registered Feature Services in Enterprise (yet).
The first script (Clone_Survey_Content_Full_Folder) takes the folder associated with the survey and clones all the content in the folder to a folder with the same name in the destination Portal.
The second script (Clone_Survey_Content_Related_Item) takes the content that has a relationship with the Form Item and clones the content to a folder with the same name in the destination Portal.
If all of your Survey content is in the same folder great the Clone_Survey_Content_Full_Folder script should work for you, but if your Survey content is located in a few different places the Clone_Survey_Content_Related_Item may be the better option.
All you should need to do in the scripts is add the Item ID for the Survey Form Item in your content, specify the username and password for both the origin and destination Portals, and if needed add your ArcGIS Enterprise Portal URL in the appropriate GIS connection.
Any update on writing a blog post on this? Also, how can this script work with orgs that use single sign-on with Microsoft Office 365? (Maybe that is a different blog post?)
As for working with SSO orgs the script uses the ArcGIS API for Python for authentication, please use this link for their documentation on working with different authentication schemes. You would need to create an application in your organization and use the client ID from that application in your GIS connection.
We have tried to run the script using three different forms. But we are getting 3 error messages (listed bellow), one for each form. They are just simple examples, with one or two questions, just created to test the script.
Any ideas on what we might be missing?
Thanks in advance!
The first error message is typically returned when there are special characters in the survey. For example in the manhole community sample one of the choice lists has these special characters as the choice labels:
These characters will cause the error message and has been logged as BUG-000146678.
For the second two errors would I be able to obtain a copy of the XLSForms used to create the surveys for testing on our end?