← Back to team overview

dhis2-users team mailing list archive

Re: need some assistant

 

Yes. This is the purpose of the "Organisation Unit Merge" function.
You just need to select the facility to remove and the one you want to
merge to, and DHIS2 should do the rest. If this does not work, you can
resort to SQL, but try the "Organisation Unit Merge" function first to
see if this solves the problem.


Not sure however about the duplicate data. I would probably remove
this data first before I tried to do the merge but maybe the
developers can comment if there is overlapping data? According to the
user manual, this should happen..

"In the sitation where data exist for the organisation unit to
eliminate and not for the one to keep, the data will be moved to the
one to keep. When data exists for both organisation units, the data
will be summarized and moved to the one to keep. When data exists only
for the one to keep, no action is taken. The organisation unit to
eliminate will eventually be deleted." What "Summarized" means though
is not very clear.





On Tue, Apr 24, 2012 at 2:46 PM, Stephen Gbanyan <mambu9@xxxxxxxxx> wrote:
> Hi Jason,
>
> Thanks for the quick respond.  To explain better let me say firstly
> two facilities was created with the same names and the only difference
> was one has a lower "C" in clinic and the other has a Capital "C".
> What we noticed was there were two persons entering data for each
> months and the same data was entered in October and November by
> difference person but in Jaurzon Clinic and Jaurzon clinic.  Starting
> from November to present they were just alternating the facilities.
> One month data was entered in Juarzon Clinic and the other month in
> Juarzon clinic.
>
> Now what needs to be done is to take those months that have data and
> move them to the appropriate facility and delete the other.
>
> Hope this explanation helps.
>
> Thanks
>
> Stephen
> On 4/24/12, Jason Pickering <jason.p.pickering@xxxxxxxxx> wrote:
>> By duplicated, you mean something like
>>
>> Juarzon Clinic has a data element = 1
>> Juarzon clinic has a data element = 1
>> and the merged facility has a new value = 2?
>>
>> In principle, you should be able to run an SQL command like
>>
>> UPDATE datavalue set sourceid = <new organisationunitid> where
>> sourceid = <old organisationunitid>
>>
>> replacing the  <new organisationunitid> with the desired facility to
>> merge to and replacing <old organisationunitid> with the facility you
>> want to get rid of.
>>
>> But this will not work if you have the same data elements entered for
>> the same month for both facilities. Then you will need to remove the
>> data elements which conflict for this time period. However, it would
>> be good if you could describe the problem with duplication in more
>> detail, as this sounds worrisome.
>>
>> Regards,
>> Jason
>>
>>
>> On Tue, Apr 24, 2012 at 12:25 PM, Stephen Gbanyan <mambu9@xxxxxxxxx> wrote:
>>> Hi All,
>>>
>>> I have a situation and need some help.  The are two facilities in my
>>> database with the same name but the difference is capital letter.  One
>>> is spell Juarzon Clinic and the other is Juarzon clinic. Both of them
>>> have the same data in for September and October 2011. In November 2011
>>> Juarzon clinic got data but Juarzon Clinic has nothing, in December
>>> Juarzon Clinic has data and Juarzon clinic has nothing and that goes
>>> on till March of this year.  When I merged organization units I
>>> noticed the months of September and October figures got duplicated.  I
>>> need a command to execute that I just move the months data to the
>>> appropriate facility and delete the other facility.
>>>
>>> Thanks
>>>
>>> Steephen
>>>
>>> _______________________________________________
>>> Mailing list: https://launchpad.net/~dhis2-users
>>> Post to     : dhis2-users@xxxxxxxxxxxxxxxxxxx
>>> Unsubscribe : https://launchpad.net/~dhis2-users
>>> More help   : https://help.launchpad.net/ListHelp
>>


References