← Back to team overview

dhis2-devs team mailing list archive

Re: Changing the parent of an org unit

 

Thanks Lars!

On Thu, May 12, 2016 at 2:29 PM, Lars Helge Øverland <lars@xxxxxxxxx> wrote:

> Hi Lorill,
>
> sure - you can use the hierarchy operations.
>
> Changing the parentid will work.
>
> Doing this on a running prod system is not recommended, however if so you
> need to i) clear the application cache (under data admin) and ii) Update
> organisation unit paths under maintenance.
>
> regards,
>
> Lars
>
>
>
>
>
>
> On Thu, May 12, 2016 at 11:14 PM, Lorill Crees <lcrees@xxxxxxxxxx> wrote:
>
>> Hi,
>>
>> I was previously unaware that there was the "Hierarchy Operations" option
>> available under the "Organisation Unit" app, so was able to do this easily
>> via the UI.
>>
>> However for future reference, if doing this via the db, is it as simple
>> as changing the parent ID for the org unit, or are there other dependencies
>> that would break because of this?
>>
>> Thanks,
>>
>> Lorill
>>
>> On Mon, May 2, 2016 at 10:57 AM, Lorill Crees <lcrees@xxxxxxxxxx> wrote:
>>
>>> Hi,
>>>
>>> We have a DHIS 2 instance where the org unit hierarchy was initially set
>>> up incorrectly for a couple districts. The districts were placed under an
>>> incorrect parent, and now we want to move them to the correct parent.
>>>
>>> What would be the best way to do this, assuming there is associated
>>> data? Can we simply change the parent ID for the org unit in the database?
>>> Or are there other dependencies that would break because of this?
>>>
>>> Please let me know.
>>>
>>> Thanks,
>>>
>>> Lorill
>>>
>>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Lars Helge Øverland
> Lead developer, DHIS 2
> University of Oslo
> Skype: larshelgeoverland
> lars@xxxxxxxxx
> http://www.dhis2.org <https://www.dhis2.org/>
>
>

References