Query to delete soft deleted tracker capture instance

I am using version 2.33.3. I deleted patient from tracker capture but it stills shows on event report. The ticket has been raised .i need a sql query to delete the soft deleted instance so that it doesn’t show up in event reports. Thanks in advance for the help :slight_smile:

Hi @sthrohit,
The patient record that was deleted will stay in event reports until there is an update on your analytics.
The analytics normally run at mid night “server time” or you can do this manually if you navigate to Data Administration. You then have to clear your cache to see your changes.

Let us know if this helpful.

StaySafe!
Emma

Hello @Emma_Kassy,
I tried running the analytics but it is reflecting the event data which were deleted. Upon further research i found out that in the programstageinstance tables the deleted column was not set to true( trackedentityinstance table deleted row was true) leading to listing in the event report. i manually set the deleted row to true from the database and the problem was solved.
Either

  • event report is listing data whose trackedentityinstance is deleted.
  • or while deleting the trackedentity instance from admin , logic to set programstageinstance tables deleted column was not set to true.