Application Development and Automation 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: 
Read only

BAPI_SALESORDER_SIMULATE: Getting wrong Net price

Former Member
0 Likes
1,991

Hi,

We are using BAPI_SALESORDER_SIMULATE to get price of a material. Problem is "in ORDER_ITEMS_OUT table NET_VALUE field is not giving the exact value. it is truncating the right most digit of the the net value."

Does anybody know how rectify this issue.

Thanks in advance.

6 REPLIES 6
Read only

Former Member
0 Likes
1,129

NET_VALUE-field length is 15 .

Regards

prabhu

Read only

0 Likes
1,129

If we create a salesorder using VA01 transaction, and suppose for a material net value in created sales order is 2345. then after using BAPI_SALESORDER_SIMULATE for the same values net value is coming as 234.

this is the issue.

Read only

0 Likes
1,129

Hi ,

what Currency field u are passing , please readposting for Negi.

regards

Prabhu

Read only

0 Likes
1,129

It is using USD as default curreny field.

I didn't get which posting you want me to go through.

Read only

0 Likes
1,129

Re: BAPI problem

Posted: Jun 28, 2006 1:49 PM Reply E-mail this post

You are using currency fields that reference a currency code. Most currencies in SAP have two decimal places. Dividing by 100 will work in most cases. Ideally you should get the CURRDEC value in table TCURX for the currency you are working with... then divide by 10 that number of times.

example-

USD, 2 decimals, divide by 10 twice.

There is a function module that will do this for you.

function modules G_DECIMAL_PLACES_GET or TCURX_READ

Read only

Former Member
0 Likes
1,129

You must enter the amount (structure ORDER_ITEMS_IN, field TARGET_QTY and REQ_QTY) multiplied by 1000.