Radio / select label value

Hi!
is there any option create a group of selects with the label mapped from an array / database? Preferably within a form. I would like to create a questionnaire with questions sourced from a database.

Hi @Ana Welcome to the forum!
Can you share some screenshots or a little more information?
Are there always a fixed number of questions? etc..

hi! I have a list of questions/values in spreadsheet (google) and want to populate labels of selects with the values using map function. Does something like grouped select components exist?

You can try using a list view component:

thanks, in that case there is no place to insert a mapped value

When using a list view you can add a text field.
So let's say you have 5 questions, you can then use i in the label

Screenshot 2023-06-19 at 11.34.43 AM

thank you, Scott !!! :slight_smile:

it actually works with mapped labels. However, used in a form it submitting data to a spreadsheet is impossible :frowning:

I would still go with the list value, but that's just me - perhaps someone else has a better idea..

also you may want to format the form data as an array and iterate over that {{formatDataAsArray(form1.data)}}

thanks! i finally did something like that in 'data to append' in my addData query

[{ "id" : {{textInput3.value}}, "employee" : {{select18.value}}, "time": {{ dateTime1.value }}, "rola" : {{segmentedControl1.value}}, {{radioGroup1[0].formDataKey}} : {{radioGroup1[0].value}}, {{radioGroup1[1].formDataKey}} : {{radioGroup1[1].value}}, {{radioGroup1[2].formDataKey}} : {{radioGroup1[2].value}}, {{radioGroup1[3].formDataKey}} : {{radioGroup1[3].value}}, {{radioGroup1[4].formDataKey}} : {{radioGroup1[4].value}}, {{radioGroup1[5].formDataKey}} : {{radioGroup1[5].value}}, {{radioGroup1[6].formDataKey}} : {{radioGroup1[6].value}}, {{radioGroup1[7].formDataKey}} : {{radioGroup1[7].value}}, {{radioGroup1[8].formDataKey}} : {{radioGroup1[9].value}}, {{radioGroup1[10].formDataKey}} : {{radioGroup1[10].value}}, {{radioGroup1[11].formDataKey}} : {{radioGroup1[11].value}}, {{radioGroup1[12].formDataKey}} : {{radioGroup1[12].value}}, {{radioGroup1[13].formDataKey}} : {{radioGroup1[13].value}}, {{radioGroup1[14].formDataKey}} : {{radioGroup1[14].value}}, {{radioGroup1[15].formDataKey}} : {{radioGroup1[15].value}}, {{radioGroup1[16].formDataKey}} : {{radioGroup1[16].value}} }]

1 Like