on 03-17-2009 1:52 PM
Hello All,
Does anyone know of a badi that is triggered AFTER a BP create or change in CRM 2007? Both PARTNER_UPDATE and BUPA_FURTHER_CHECKS fire before BP create/change. We are attempting a delta export of changed/created BPs for export to an external system. So if you know of a programmatic or configuration way to trigger this, it would be greatly appreciated.
Thank you,
Derek Winters
I am not sure about BADI , But you can follow a different design model/very reliable
Business Object event . BP BUS1006 . Every time a BP is created/chnaged BusinessPartner.created
BusinessPartner.changed events will be triggerred by the system .
You can Trigger a workflow with single step/very basic ...call a Function Module ..do whatever you want
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi there,
I need the exact same.
I assume there is no such BAPI that interacts after the BP was saved (created or changed)?
Unfortunatelly I'm not familiar with Business Object events. Can one of you or someone else provide steps how to create a Business Object event (for BP)?
Thanks!
Best regards,
Melanie
Hi Derek,
PARTNER_UPDATE is very much the correct BADI that can be used here. In fact the ENTIRE concept of data exchange and synchronization of BP master data to other systems is built on this BADI ! This badi triggers the outbound which sends data to external systems.
The only thing to look for here is - how to get the created or changed data in the implementation of this BADI. You can get this using the modules BUPA_GENERAL_CALLBACK, and other BUPA*CALLBACK modules for the respective datasets.
Otherwise, PARTNER_UPDATE is definitely going to help you.
Regards,
Rishu.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rishu,
I'm afraid but PARTNER_UPDATE didn't work for me. My request is to automatically add a partner function to every BP that is being created.
So I used BUPA_GENERAL_CALLBACK to determine if the partner is created or changed and for created partners I want to add a partner function using BAPI_BUPA_PFCT_ADDFUNCTION. But if I try to do that I get a SYSTEM_ON_COMMIT_INTERRUPTED dump - which makes sense.
So I really do need another BAPI (or Business Object event or even something else) where I can interfere after the BP has been created (after the COMMIT).
Has anyone ideas?
Best regards,
Melanie
Hi again,
In case anyone is interested...
I actually didn't need a BAdI that interacts after the BP has been created/saved - or in other words, that interacts after the COMMIT. All I needed is a function module which I can call in update task and that did the trick.
So I did use the PARTNER_UPDATE BAdI. I'm calling there my update-function-module which creates a partner function => I'm using BAPI BAPI_BUPA_PFCT_ADDFUNCTION.
So this is how I've done it in the IF_EX_PARTNER_UPDATE~CHANGE_BEFORE_UPDATE method:
data: lt_but050_old type standard table of but050,
ls_but050_old type but050,
lt_but050_new type standard table of but050,
ls_but050_new type but050,
ls_rel type but050,
ls_rel_old type but050.
* get relationships ****************************************************
call function 'BUPA_BUT050_CALLBACK'
tables
et_but050_old = lt_but050_old
et_but050_new = lt_but050_new.
* try to get relationship "Responsible Employee"... ********************
read table lt_but050_old into ls_rel_old
with key reltyp = 'BUR011'. " Responsible Employee
read table lt_but050_new into ls_rel
with key reltyp = 'BUR011'. " Responsible Employee
if ls_rel_old-partner2 ne ls_rel-partner2
and ls_rel-partner2 is not initial.
* ...add partner function "Sales Representative" *********************
call function 'Z_CRM_BP_FRG0081_SAVE' in update task
exporting
iv_partner1 = ls_rel-partner1
iv_partner2 = ls_rel-partner2
iv_partner_fct = '00000012' " Sales Representative
iv_relnr = ls_rel-relnr
exceptions
invalid_partner1 = 1
invalid_partner2 = 2
others = 3.
endif.
Best regards,
Melanie
User | Count |
---|---|
7 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.