seasketch / next

A modernization version of the SeaSketch platform, released in 2022.
https://seasketch.org
BSD 3-Clause "New" or "Revised" License
6 stars 0 forks source link

Exported survey responses only contain first value of multi-select multiple choice questions #723

Closed petermenzies closed 3 months ago

petermenzies commented 3 months ago

In a survey, when a multiple choice question has the "Multiple Select" option turned on, responses to that question that have selected multiple values only export with the first selected value.

I first noticed this in the Fiji OUS when multiple choice shape attributes were exporting this way. I then did some testing in one of my sandbox surveys and found this was happening for non-spatial questions as well. In the survey dashboard data viewer I can see the multiple values recorded, despite the exported files not including all the values.

underbluewaters commented 3 months ago

Looks like the export utils always coerce these values to a single string. It seems the right thing to do would be to always coerce the value to an array when multiple-select is enabled. Would that break any downstream processing you are doing? I can go ahead and make a fix but I'm hesitant to do so in case I break your apps.