Unable to sync stages with option sets

Hi

Some users using the androind app are complaining that are not able to sync stages that have a data elements using option sets. When syncing it returns an error saying: “Value *** is not a valid option code of option set: ***”
See the following screenshot of the error

I tried using the web interface to replicate the reported issue, and the given value of the option set did not appear when I searched for it.
After that I went to the maintenance->option sets and searched for that value and could not find it.
But when I download the the option set metadata, I’m able to find the option value

What could be the reasons for this odd behaviour

Android app version: 2.9.1.1
Dhis2 version: 2.9.5

Best regards

Hi @joao.machiana,

when you mention that you download the option set metadata, do you mean by using the web API? If so, which request are you using?

Do you know if that value was filled in by the users themselves? or at least, are they able to see the value in the dropdown list of the optionsSet? Maybe the value already existed before and it was removed from the optionSet

Hi @vgarciabnz
I got the metadata by downloading it from Import/Export app

I’ve got an update on this issue. For some reason, some options (values) are not associated with an option set, but are listed on option set group.
How is this possible? Do option sets have a limit of options to add? And after reaching that limit number some options will be removed from the option set.

Best regards

Hi @joao.machiana,

options should belong to an optionSet, otherwise they shouldn’t be listed on an optionSetGroup. Maybe you can try to manually clean the optionGroup in Maintentance. Just open the optionGroup and leave the options that are relevant.

1 Like