cancel
Showing results for 
Search instead for 
Did you mean: 

Archiving a Medical Service

Former Member
0 Kudos

Hi all,

my users have made a mess with Medical Services, so they asked to erase the database.

I've explained that you can't simply delete things in SAP, but I was wondering if I could archive all wrong data with SARA transaction.
Any help on that?

Thanks,

Daniele

PS Is there another way to "clean" delete a Medical Service? I told them that after status 2 it's not possible to delete the MS. any badi or bapi or exit?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

well, let's try to be more specific..

I need to know if there is an Archiving Object for Medical Service(s)

It seems that in SARA you had no archiving objects for Services..

former_member198518
Participant
0 Kudos

Hello,

Archiving is not available for EH&S data. The only data that can be archived is EH&S reports.

The deletion of a medical service is just possible for medical services that are in status "New service" or "Appointment made" for both status is possible to delete the entry, and no data is saved on the system. It's logical considering that medical services in this status could be created incorrectly and a deletion should be possible.

But for status "Examination started","Service closed" and "Service reopened" you cannot delete the medical service because there's relevant data.

The medical services are stored within table T7EHS00_SERVICE. You only can remove them from there manually or due to a customer report. Please note that all the dependent data like protocols, examinations etc. have to be removed too in order to avoid inconsistent data.

Best Regards,

Camila Zilles

Former Member
0 Kudos

Camila,

I already knew the table (if you look at the image I tried to search archive objects in that table, via SARA) .

Definetely I'll not delete the records from T7EHS00_SERVICE, because I don't know how many side effects may occurr in T7EHS00_SRV_EXA, T7EHS00_SRV_PROT, and the other 29 tables T7EHS00_SRV_*

Same thing for Medical Services status, if you read my PS I was asking for a badi after status 2.

I know T7EHS00_SRV_STA but I was searching for a function module or a badi instead of manually change the status to delete services once done.

And what about the assignments of range numbers? I should reset them too.

Maybe I should open a ticket at SAP AG to add an archive object, what do you think?

Cheers,

Daniele

jagadeesh_gn
Employee
Employee
0 Kudos

Dear Daniel ,

You may try the below function module to delete all contents of closed services /open service

FM:"EHS00_SRV_DELETE_DEP_DATA"

Also you may try modifying in the lines of a standard program to delete from database but am not sure what impact it might have.

REHSOH_DELETE_DB               Deleting Database Contents for Occupational Health

Thanks

Jagadeesh

Former Member
0 Kudos

Hi Jagadeesh,

that FM does not seem to delete the Service, but any analisys on that service.

Anyway, I've created a report with my ABAP developer which resets the Medical Service to Status 1 (Created) so our user can easily modify all the data or even delete the whole service.

Answers (0)