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: 

BAPI for VA01: For pricing calculation

Former Member
0 Kudos

Hi,

I need BAPI to calculate the price.

The price calculation functionality should be exactly like, what happens in VA01.All the elements like price, discount,tax,freight,etc. everything should be calculated and return the values.

Thanks.

5 REPLIES 5

Former Member
0 Kudos

Hi,

I'm not sure if there is a BAPI for this but in the past we actually created our own RFC and called a standard SAP function module to calculate the pricing.

Function Module "GN_INVOICE_CREATE" can be used to calculate the price. The function module is not RFC enabled so you will have to create your own RFC enabled function module(wrapper) to call the SAP function module.

Hope this helps.

Jerrod

Former Member
0 Kudos

Hi,

try to use the direct input Functionmodules 'SD_SALES_HEADER_MAINTAIN' and 'SD_SALES_ITEM_MAINTAIN' to create temporarily a SD-order.

With function 'SD_SALES_PRICING_INFORMATION' you should get the calculated prices in table FXKONV (same as KONV), or try function 'SD_SALES_ITEM_TABLES_READ' to get the information.

0 Kudos

Hi Micheal,

Do you have any sample code for this?

Thanks

former_member188685
Active Contributor
0 Kudos

Check the Function module <b>PRICING</b>

Regards

vijay

Former Member
0 Kudos

Hi,

Use the BAPI BAPI_SALESORDER_SIMULATE to get the simulated price as if the Sales order is created (No order will be created, only the value will be captured from simulation).

Pass the Order header info, like Document type, Sales area, PO #..

Along with the item details like item #, Material #, Quantity, UoM, Plant..

It will give the details about what information your order contains if created on DB with same info.

ORDER_CONDITION_EX table parameter contains the pricing result.

Hope this helps.

Regards,

Nagaraju Chidurupalli