Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Delete attachments linked with a business object

Former Member
0 Kudos

Hi All,

I have added some pdf attachments to a business object using Archivelink. I am making use of FM - ARCHIV_CREATE_TABLE.

This worked. Now we need to either add a retention period for these attachments or archive them or delete them after a certain period of time. I tried some ways till now.. but they havent worked

1. Setting a delete date in my FM ARCHIV_CREATE_TABLE :

CALL FUNCTION 'ARCHIV_CREATE_TABLE'

EXPORTING

ar_object = <archiveobj>

DEL_DATE = '20100624'

object_id = l_arc_doc

However when I look in OAAD, this delete date doesnt show up!

2. Using standard reports - RSBCS_REORG, RSSO_DELETE_PRIVATE and RSSODFRE. However my attachments are not even getting selected to be deleted.

3. I also tried with FM - archive_object_delete and ARCHIVOBJECT_DELETE. Here I am getting an error that states-

Error during import of physical document from cluster table SOFFCONT1.

Any ideas towards this ? All your answers are appreciated.

Thanks, Liz

3 REPLIES 3

Former Member
0 Kudos

All,

Minutes after I wrote up this question, I tweaked a way to delete the PDF using FM -ARCHIVOBJECT_DELETE. The archive doc id to be given here is from the 'Link' table one would have configured in transaction OAC3 (part of Archivelink config).

I would still like to know if there is a cleaner way to delete the attachments from a business object.

Also is there is way to delete the 'link' from transaction OAAD.

Your input is appreciated!

Thanks, Liz

0 Kudos

All,

Link was deleted with Tcode SARA (I had to do this deletion after the retention period (set as one month) passed.

Thks, Liz

mgbernardo
Participant
0 Kudos

Hi Elisabeth,

You can use this function to achieve your requirement:

ARCHIV_DELETE_META

Though I think you won't be able to handle deleting dates from it

Hope it helps

Regards