SAP for Retail Discussions
Join conversations about personalization, omnichannel strategies, and operational excellence in retail using SAP for Retail software.
cancel
Showing results for 
Search instead for 
Did you mean: 

BADi PWL_SP_DETERMINATION is not working

nmirandaghn
Participant
0 Kudos

Hi, according to this paper 'Processing the Pricing Worklist - Procedures' (http://help.sap.com/saphelp_470/helpdata/en/12/0851e0470311d1894a0000e8323352/content.htm), I could manipulate the end price of a material. I specifically implemented the BADi 'PWL_SP_DETERMINATION' for transaction WVN0, procedure 'IF_EX_PWL_SP_DETERMINATION~CALCULATION_ITEM_MODIFY', in order to change it with a formula, however, it does not change any price. When I debug it, it changes the field 'px_i_kalp-endpr' correctly but the final result is other price, the system is using the standard formula, is like if it ignores the results of my code.

Is there something else that I'm missing?

This is my testing code

method IF_EX_PWL_SP_DETERMINATION~CALCULATION_ITEM_MODIFY.

 

  data kbetr type kbetr.

          " Apply a value to kbetr, testing

          move 5 to kbetr.

  px_i_kalp-endpr = px_i_kalp-vkpne * ( 1 + ( kbetr / 100 ) ).

 

endmethod.

Thanks in advance

1 REPLY 1

nmirandaghn
Participant
0 Kudos

Finally did it, it was my error, I posted the correct code instead of the wrong, in other words I copied the code corrected for testing instead of the wrong one. Then I run it and it worked, sorry, my fault.