I am trying to populate a list using data from a table (person_info). This table (person_info) is auto-populated/updated from an outside source. In a perfect world, my survey would go as follows:
- The user enters their name in the first field, autocomplete-ed from person_info that is already stored in
ArcGIS REST Services. - The next field is auto-populated by a calculation made on the first field, this second field selects their supervisor.
I've spent a lot of time searching and trying new ways and cannot get it to work. I even tried to convert the feature table (person_info) into a feature layer to utilize the search() appearance function as it is exactly what I needed. I read that using search() over pulldata("@layer") in this case, was preferred. (There are no 'geotags' in person_info so I understood I had to do some joins before creating it into a feature layer)
Maybe I am not getting the syntax correctly or my data is set up improperly? Will I have to create a whole script using pulldata("@javascript") that does everything at once... searches the user's name and their supervisors'? I know that some people taking the survey may not have an ArcGIS account. Would some sort of authorization be needed like a token or an API key?
Is there a way to pull straight from a feature table?
Below is what my general idea is using pulldata() and search():
Pulldata()
pulldata("@layer", "getValue", "attributes.fname", "https://root.com/arcgis/rest/services/database/person_info/FeatureServer/0", arg)
Search()
autocomplete search('subname?url=https://root.com/arcgis/rest/services/database/person_info/FeatureServer/0')