cancel
Showing results for 
Search instead for 
Did you mean: 

BBP_PD_CTR_UPDATE and BBP_PD_CTR_SAVE

Former Member
0 Kudos

Hi Experts!! I am facing an issue.

I am trying to set a custom fields on the contract line item to X once a given event happens. I am calling BBP_PD_CTR_UPDATE and then BBP_PD_CTR_SAVE but nothing happens.

I am calling BBP_PD_CTR_UPDATE with the following parameters:

EXPORTING

i_header = " GUID of the contract"

i_save = 'X'

IMPORTING

ES_HEADER = wa_ES_HEADER

TABLES

i_item = it_item (filled with the ITEM's GUID that we need to change)

We then call BBP_PD_CTR_SAVE with the GUID imported by the previous function module.

Nothing happens though. When I check on the contract item the flag is not set.

thanks a lot in advance!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Get all the information of the contract using BBP_PD_CTR_GETDETAIL, the map the values to BBP_PD_CTR_UPDATE structures & tables. While mapping modify the required data and call this FM.

After the function call is over then execute the function BBP_PD_CTR_SAVE with the GUID returned by BBP_PD_CTR_UPDATE.

Hope this helps.

Regards

Kathirvel

Former Member
0 Kudos

Thanks a lot for replying!!

Just one additional question: I have both contract header and contract items GUIDs, but when I call the function BBP_PD_CTR_UPDATE - in order to map the information - do I need only to passs the GUIDs? Meaning that I will put in the header structure the Header GUID and in the Item structure I will put both the Item GUID and the Parent GUID = Header GUID. I will then populate the fields I need to change...

Is this enough or am I supposed to do anything else? because it is still not working..

Thanks a lot!!

Former Member
0 Kudos

You get all the information using BBP_PD_CTR_GETDETAIL.

1. Copy all header data from getdetail to your update header.

2. Copy all item data to your update item data, whilst you are doing this copy change the data to your needs. So if you only change a price, leave the other fields intact with the getdetail data.

3. Call the BBP_PD_CTR_UPDATE fm with the update header and the update item data

4. Call the BBP_PD_CTR_SAVE fm with the returned changed header guid

5. Last but not least do a "COMMIT WORK"!

Regards,

Robin

Answers (0)