cancel
Showing results for 
Search instead for 
Did you mean: 

Change PO Vendor field on APO using user-exit APOCF006

Former Member
0 Kudos

Hi guys,

I need some help.

By receiving PO in APO from R3 by CIF I need to delete value in 'Vendor' field (it must be blank, or alternatively a fixed value different from original value).

So I've implemented badi /SAPAPO/CIF_PO_INBOU (method: CHANGE) and then also tried to do the same by user exit 'EXIT_/SAPAPO/SAPLCIF_PU_001' (APOCF006) but field 'Vendor' has never been changed.


I tried also by changing quantity, plant and some other fields of PO and it worked fine for these ones, but it seems like Vendor field must be valued after this step.

I've modified CT_OUTPUT table by passing new value for Vendor and CT_OUTPUTX with VENDOR = 'X' for badi.

Same logic used in IT_OUTPUT and IT_OUTPUTX for user-exit.

Tried also adding 'COMMIT AND WAIT' at the end of processing, no results.

Do I need any other activity to get my PO-Vendor field cleared?

Thank you in advance.

Accepted Solutions (1)

Accepted Solutions (1)

sourabh_jain66
Active Contributor
0 Kudos

Hi Rosario,

Please try to debug the scenario, if vendor value is being over written by some other values after changing as per your logic.

Rgds

Sourabh

Former Member
0 Kudos

Hi,

we moved on quality environment to test our modify - too few data on dev - and it worked!

In short, data where sent to APO two times (by mistake), wiping out modifications done in BADI.

Thank you Sourabh and Hubert.

sourabh_jain66
Active Contributor
0 Kudos

That's a good news, you find the reason for the issue

Answers (2)

Answers (2)

hubert_spohn
Active Participant
0 Kudos

Hi,

I think you also have to clear field information about the source of supply in fields "con_number / con_item" (number of purchase info record for example) otherwise the system still knows the PO's vendor.

Regards.

Hubert

Former Member
0 Kudos

Hi Guys,

May I know how did you change the vendor successfully?

hubert_spohn
Active Participant
0 Kudos

Hi Elmer,

I suppose it described above how it is done. The question is how your process shall look like, there might be some additional setting necessary like

- adjusting table loc_ali

- adjusting the PIR inbound

etc

In addition: are we talking about POs (one way transfer) or about PREQS (both directions) ?

Hubert

Former Member
0 Kudos

Hi Hubert,

Am in the process of creating a PO in ECC side and transferred it to APO. But once the PO is CIFed into APO, we need to change the vendor number from '0000024423' to 'C24423'. Must be prefixed with 'C' removing the leading zeroes.

I've modified the exit EXIT_/SAPAPO/SAPLCIF_PU_001 using the IT_OUTPUT table by passing new value for Vendor ie  'C24423' and IT_OUTPUTX with VENDOR = 'X' for badi. But it doesnt work.


Could you please help me on this? Is there anything I need to do before hand?

Thank you so much for your help.


Elmer

hubert_spohn
Active Participant
0 Kudos

As already mentioned in 2013:

Hi,

I think you also have to clear field information about the source of supply in fields "con_number / con_item" (number of purchase info record for example) otherwise the system still knows the PO's vendor.

Regards.

Hubert

sourabh_jain66
Active Contributor
0 Kudos

Hi Rosario,

Please try to debug the scenario, if vendor value is being over written by some other values after changing as per your logic.

Rgds

Sourabh