cancel
Showing results for 
Search instead for 
Did you mean: 

Update Custom Table on Document Save

Former Member
0 Kudos

Hi There,

My requirement is to update a custom table when I save a document (ex:Shopping Cart/RFx/PO). I am planning to use the BADI BBP_DOC_SAVE_BADI to insert/update data in a custom table. I have to insert/update the data only based on a certain condition, for example when the document status is changed (Approved/Released/Published).

In the BADI method BBP_DOC_SAVE, I am planning to use Business Object specific GETDETAIL function module to read the current document data. I am assuming that E_STATUS gives me all the statuses the document went through (active and inactive). My question is 'How do I know what is the latest document status'?

Any help or hint is appreciated.

Thanks,

Chan

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Chanukya,

Try using this function module.

/SAPSRM/SRM_DOC_STATUS_GET.

Pass Object Type, GUID, and IT_STATUS and it returns you the most important status of the document.

Regards,

Karthik Babu