Hi CommCare Group!
We have many single select questions in our application, some with a large number of possible choices. For each choice, there is a label (which can contain spaces and characters) and then a choice value (which cannot contain spaces but in our case is always exactly the same as the label with underscores instead of spaces). The annoying part is that when this question is stored as a case property and then displayed in the case list (or case details), it always has the underscore. I would like to remove this.
Clearly the case lists/details do not have a limitation on spaces because text questions can be displayed with spaces or characters. I also know how to use the ID mapping to map each choice onto a string. However, if we use ID mapping we will not only have to re-type hundreds of mappings that have already been defined elsewhere in the application, but it will also make it harder to add choices in later versions of the application without having to change a lot of instances of the same thing. It seems like a whole lot of work to do when all we want is all of the underscores to be replaced by spaces.
One solution I thought of is to copy the single select question into a hidden value (hidden values can support spaces) and then save the hidden value to the case rather than the single select. Unfortunately, there don't seem to be any functions that allow string manipulation, so this didn't work as I had hoped.
Any ideas/solutions? Thanks! -Jennifer