I am facing a problem while trying to create an orgUnit and assign a dataSet.
Specifically, I have tried two options:
- Assign the dataSet while creating the orgUnit, here some sample json:
... the orgUnit is created but nor dataSet assigned
- Assign the orgUnit to the dataSet, here some sample json:
{"dataSets":[{"id":"uceRzlqmJeg","organisationUnits":[{"id":"bJgURXB4miQ"}]}]}
... the original dataset is overwrite and dataElemts and previous assigned orgUnits are losed.
Then, I realized the posibility of "Adding and removing objects to/from collections" using this syntax : /api/{collection-object}/{collection-object-id}/{collection-name}/{object-id}. Therefore, I tried :
- http://localhost:8080/dhis216/api/dataSets/uceRzlqmJeg/organisationUnits/Bj9hub0yvwo
- http://localhost:8080/dhis216/api/organisationUnits/Bj9hub0yvwo/dataSets/uceRzlqmJeg
Nov 04, 2014 11:03:06 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [webapi] in context with path [/dhis216] threw exception [Request processing failed; nested exception is java.lang.NullPointerException] with root cause
I am sure, that one of these options has to work but I can not figure out my pitfall. Any help is welcome.
Thanks in advance.
Regards,
Octavio.
_______________________________________________ Mailing list: https://launchpad.net/~dhis2-users Post to : dhis2-users@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-users More help : https://help.launchpad.net/ListHelp