cancel
Showing results for 
Search instead for 
Did you mean: 

Changin BP fields before save

Former Member
0 Kudos

Hi,

I have a requirement where I need to validate few fields of BUT000 before saving the business partner.Can any one provide some information regarding this.

I could see partner_update is being called, but I am not sure how to retrive and write values into BUT000 table fields.

Request any one to help in this regard.

Thanks,

Aruna.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

solved

Former Member
0 Kudos

Hi Aruna,

You don't need to use the PARTNER_UPDATE Badi since this is called AFTER save. Instaed, there are 2 better approaches.

1. If you are using transaction BP to create/ change the Business partners, then the solution is to create a custom module containing the checks and register it in the BDT event DCHCK. You can access the event DCHCK using transaction BUS7. Choose event DCHCK, click on Event-> function modules. Register your Z module here. It will get called whenever you press the syntax check button on the screen,or try to save the BP.

2. If you are using CRM Web UI/ BAPIs you can implement the BADI BUPA_FURTHER_CHECKS. This will check your data before save.

I hope this solves your issue.

Cheers,

Rishu.

PS : I assume "validate" would refer to checking the data . You cannot change the data, but just check it. The only way to change the data is by making a modification to the standard code.

Former Member
0 Kudos

Hi Rishu,

My requirement is while creating a customer, I need to create a BP and through standard synchronization I am getting this, but we need to populate the additional fields as well.

so request you to provide some information on this.

Regards,

Aruna.

Former Member
0 Kudos

Hi Aruna,

Ok, this actually is very very differnt from what your initial question seemed to ask !

Anyhow, the CVI synchronization only maps the COMMON data between customer and BP - and this includes fields such as name, address, bank details, credit cards. The additional data fields belong entirely to KNA1 and do not get mapped at all - and do not need to get mapped either. For display on the screens in transaction BP, the data is directly picked up from KNA1, unlike name,etc which are synched and stored in BP tables.

Hence, these fields will not get synchroznized at all. You just need to maintain them once in XD01/XD02, and they will get saved in KNA1 - and that's all. Transaction BP will now read them from KNA1.

Hope this helps.

Cheers,

Rishu.