Pulldata returning error message

3435
23
Jump to solution
02-12-2018 12:32 PM
KendraStraub
New Contributor II

I have loaded external data into the media folder in my Survey123 folder.

GRSM_species_list is the exact name of the csv in the media folder. 

cover_lookup is another csv in the media folder. 

I am not sure how to interpret the error message I am receiving. #

When I publish the form I get the following error message:

Error: Initialing Form...

  • External instance "GRSM_species_list" is empty.
  • FormLogicError: instance "cover_lookup" does not exist in model
1 Solution

Accepted Solutions
JohnathanHasthorpe
Esri Regular Contributor

Hi Kendra

You are right, we should not use concatenate to add numbers. I have fixed the xls and attached.

Here is the published survey: https://survey123.arcgis.com/share/8e2bc082e19d44beabc0ade8ffb7a13a it does work on the web.

Can you make sure you are using the complete survey (all files not just the xls) as I made edits to all files.

Also can you let me know what version of Connect you are using? As well as the web browser version.

You should also clear your browser cache just in case.

We will get this working for you!

Cheers

John

View solution in original post

23 Replies
JohnathanHasthorpe
Esri Regular Contributor

Hi Kendra

The form has a couple of issues:

1) You are using + instead of the concat() function. The webform does not support the use of + to create a string

2) The .csv has a column title with spaces in it - try updating it to be: GRSM_Scientific_Name_GRSM_Code_USDA_Code_USDA_Common_Name

Fix those two things and the form will run.

Thanks

John

KendraStraub
New Contributor II

Thanks Jonathan! 

I am using + not to concatenate into a strong but as a simple calculation. Is the problem that the results of the calculation can't be displayed in a notes field? 

It is odd because this survey, the same way it is, worked last spring but no longer works. Perhaps there have been updates that have affected these behaviors?

Thanks again, 

0 Kudos
KendraStraub
New Contributor II

Thanks again Jonathan. This solved the follow error:

  • External instance "GRSM_species_list" is empty.

I am still getting this error:

  • FormLogicError: instance "cover_lookup" does not exist in model

-No spaces in column headings

-Can't find any issues in the pulldata calculations that are using the cover_up csv

-cover_lookup.csv is in the media folder

Appreciate it! 

0 Kudos
JohnathanHasthorpe
Esri Regular Contributor

Hi Kendra

The thing that is causing this issue is the following: 

int(pulldata('cover_lookup','value','cover',${T2_Range})) - note that there are a few examples of this in your survey.

This returns an integer, but you are using it to update a text question.

You should remove the int() statement - or use a integer or decimal question instead.

Please let me know if you need any further assistance with this.

Thanks
John

0 Kudos
KendraStraub
New Contributor II

Hi John, 

Your point makes sense. I understand that I was using an integer to populate a text field and why that doesn't make sure. Thanks. 

I went ahead and tested both

-Changing all fields with int() to integer fields--> same error

-Leaving those fields as text and then removing int() from the calculation--> 

I even went ahead and removed all of the fields with those troublesome calculations and then I still got the same error. 

Thank you in advance for any help, 

0 Kudos
JohnathanHasthorpe
Esri Regular Contributor

Hi - Attached is the full working survey.

You can just unzip and copy into your my survey designs directory (C:\Users\XXXX\ArcGIS\My Survey Designs)

and publish from connect.

Please let me know how you get on

Thanks

John

0 Kudos
KendraStraub
New Contributor II

Hi John, 

Thanks for sending the updated form, very helpful. One remaining issue is that concat won't work in this instance. We don't want a concatenated string of values, we want to sum of several integers. 

If we use concat we end up with, something like 30 + 40 = 03004000

This zipped version works in that is provides the sum of the values we are looking for. I experience no error in Survey123 Connect when testing, but when I publish, I get the same error: FormLogicError cover_lookup does not exist in your model. 

Perhaps this means it will work in the iPad app, just not in the web app?

0 Kudos
JohnathanHasthorpe
Esri Regular Contributor

Hi Kendra

You are right, we should not use concatenate to add numbers. I have fixed the xls and attached.

Here is the published survey: https://survey123.arcgis.com/share/8e2bc082e19d44beabc0ade8ffb7a13a it does work on the web.

Can you make sure you are using the complete survey (all files not just the xls) as I made edits to all files.

Also can you let me know what version of Connect you are using? As well as the web browser version.

You should also clear your browser cache just in case.

We will get this working for you!

Cheers

John

KendraStraub
New Contributor II

Hi John, 

Thanks for sticking with me through these issues. 

-I have cleared my browser cache

-I am using Google Chrome: Version 64.0.3282.167 (Official Build) (64-bit)

-I was using Survey 123 Connect 2.5.44. But I just updated to 2.6

Everything is looking great and working great in Connect.

I published it and it doesn't work (as we expected) in my browser. We will be testing on iPad soon. Will keep you posted. 

Thanks so much! 

Kendra 

0 Kudos