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: 

Whether basic data, company code data or purchase org data is changed for vendor...

Richa_Gupta
Contributor
0 Kudos
87

Hi,

I need to develop a logic for an IDoc where in I need to find out if the basic data of vendor is changed, or is it company code level data or the purchase org data. There could be the cases where all of three gets changed.

I found a BAdi for it 'VENDOR_ADD_DATA' but it is importing activity as 'V' only for any kind of change due to which I am not able to recognize that which change was made.

Could you please help me with this?

Thanks in Advance.

Regards,

Richa

3 REPLIES 3

Former Member
0 Kudos
53

Hi Richa Gupta,

You could check some changes on tables CDHDR & CDPOS!

A few weeks ago, I had to create a RFC to get all customers created/modified between 2 dates (last 2 days), so I read those tables to do this!

This process its similar for vendors!

Let me know any concern about it!

Best regards,

Alexandre B. Dambrowski

0 Kudos
53

Hi Alexandre,

Thanks for your input but unfortunately, I don't think CDHDR and CDPOS logic will fit into my requirement.

My requirement is to trigger the IDOC once the changes of vendor are saved in XK02. So, to trigger the IDOC I need to populate those segments where the changes are done. And this thing I am doing in a BAdi. And the changes are saved in CDHDR and CDPOS after the BAdi code is executed.

Richa

0 Kudos
53

Hi Richa,

You certainly could use these tables on a period job to send this data, but don't on real time, triggering the IDOC process.

Maybe you'll able to do this using the userexit "EXIT_SAPMF02K_001" (Enhancement "SAPMF02K") and accessing those changes from LFA1 by field-symbol. For example, to see new values from LFA1 => "(SAPMF02K)LFA1", meanwhile "(SAPMF02K)YLFA1" has old values from LFA1.

Good luck!

Regards from Brazil!

Alexandre B. Dambrowski