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: 

How to reprice specific condition types in sales order using BAPIs?

0 Kudos
526

Hi Experts,

As part of business requirement, We have to reprice the sales order for specific condition types in simulation mode and actual repricing mode i.e. After changing the pricing date only desired condition types should be updated with new price and remaining all condition types should remain unchanged. In VA02 we can achieve this manually.

But if I try to update condition types through BAPI facing below challenges.

For simulation, I am using BAPI_SALESORDER_SIMULATE. here we are not having provision to pass pricing type ( e.g. KNPRS = H for freight charges update).

For Actual Repricing, I am using BAPI_SALESORDER_CHANGE. here we have provision to pass pricing type ( e.g. KNPRS = H for freight charges update) in importing parameter LOGIC_SWITCH-PRICING but it is accepting only B,C or G value and getting BAPI return error as "H is not allowed for LOGIC_SWITCH-PRICING" when I am passing 'H' for updating freight charges. Resulting, I am unable to reprice the Sales order for specific condition types.

Will you please help me here?

1 REPLY 1

AlexGourdet
Product and Topic Expert
Product and Topic Expert
0 Kudos
389

Thank you for visiting SAP Community to get answers to your questions.

As you're looking to get most out of your community membership, please consider include a profile picture to increase user engagement & additional resources to your reference that can really benefit you:

I hope you find this advice useful, and we're happy to have you as part of SAP Community!

All the best,

-Alex