1. What is the problem? Be very detailed.
I have four select_one options in my survey. They are Reg, Prv, Mun, and Bgys. After adding the list for Mun and Bgy, testing on ODK collect started lagging(slow) a lot.
I have heard that you can lessen the loading time using csv or external selects, but I do not know nor understand how to do it..
2. What app or server are you using and on what device and operating system? Include version numbers.
ODK Collect, Google Drive xls as server; android phone
3. What you have you tried to fix the problem?
I have tried external select, but for some reason, the choices doesn't appear on Collect.
4. What steps can we take to reproduce the problem?
I added Reg-Prv-Mun-Bgy lists on external_choices tab
I have used forms with thousands of records in an external csv file and they are usually quite fast (they might only take a bit of time the first time the form is launched and the csv preloaded).
I would suggest you try:
to create unique codes for the different geographical levels. This way you would not need to apply multiple conditions to filter the options for the lower levels. Using codes instead of names could avoid duplicates.
use type select_one and search() function in appearance. Idk if this is faster by design, but it usually works well for me. And, together with the previous point, you would not need to have choice_filter
Syntax is:
search('supportfilename','matches','field_in_csv',${variable_of_upper_level})
See sample file attached sample_dynamic_search.xlsx (31.9 KB)
You would use this in combination with a csv that has 4 columns (or more), including: dis_id, chi_id, sec_id, loc_id
The district selection is a simple search in the external file.
The other levels filter the choices based on the previous selection.
Other options for the second argument, are:
'contains'
'startswith'
'endswith'
If your csv file is big, consider using the "_key" suffix to name the columns to force index creation on the mobile side.
Check the pre-loading data section of this page : https://xlsform.org/en/#pre-loading-csv-data