← Back to team overview

dhis2-devs team mailing list archive

Re: Fast/bulk delete of events


The easier way is to use the api/events endpoint and query for events uids
you want to delete. Once you have them, you can send http delete method via
curl or nodejs or python or php,etc and loop through each to delete them
via api/events/uid.


On Wednesday, January 24, 2018, Petar Jovanovic <petar@xxxxxxxxxxxx> wrote:

> Hi,
> We want to quickly (in groups) delete events related to a specific program
> and/or to a specific org unit (or list of org units). In DHIS2, we only
> managed to go one by one in the event capture app.
> Can anyone recommend us any other convenient and faster way to do this, or
> if you are aware of an app that may help us?
> We have also checked if it is possible to do it through the database, but
> we did not find easy to locate the table where the event data are stored
> and it is safe to delete them without loosing references to other objects.
> Thank you!
> Best,
> Petar
> --
> _________________________________________________________________
> Petar Jovanovic
> Department of Service and Information System Engineering (ESSI)
> Universitat Politècnica de Catalunya, BarcelonaTech
> Barcelona, Spain
> _____________ http://www.essi.upc.edu/~petar/ ___________________
> _______________________________________________
> 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

Alex Tumwesigye

Technical Advisor - DHIS2 (Consultant),
Ministry of Health/AFENET  | HISP Uganda
+256 774149 775, + 256 759 800161
Skype ID: talexie

IT Consultant (Servers, Networks and Security, Health Information Systems -
DHIS2, Disease Outbreak & Surveillance Systems) & Solar Consultant

"I don't want to be anything other than what I have been - one tree hill "

Follow ups