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

Problem when using BAPI_SALESORDER_CREATEFROMDAT2

Former Member
0 Likes
397

Hi,

I am using BAPI BAPI_SALESORDER_CREATEFROMDAT2 to create sales order and it is working fine.

System determines prices using pricing date and pricing procedure but I am trying to overwrite the prices in item conditions. BAPI instead of modifying the prices in the new sales order it is inserting another line of same condition type using the value passed through the BAPI.

example:

COndition type Price

PR00 49,500.00 --> determined by

standard procedure

PR00 500.00 --> value passed through

the BAPI

My new sales order should consist of only one line

PR00 500.00

I am passing following fields to ORDER_CONDITIONS_IN table

COND_VALUE

CURRENCY

COND_P_UNT

COND_UNIT

ITM_NUMBER

COND_TYPE

and in ORDER_CONDITIONS_INX table

COND_VALUE

CURRENCY

COND_P_UNT

COND_UNIT

ITM_NUMBER

COND_TYPE

UPDATEFLAG

Is there any way to avoid the line determined by std procedure?

Please suggest me a solution.

Thanks,

Sonali.

1 REPLY 1
Read only

uwe_schieferstein
Active Contributor
0 Likes
331

Hello Sonali

I am currently working on this BAPI, too.

I create my orders without using any of the ...X structures (because they are not necessary when creating an order). Thus, give it a try and do NOT pass any values in ORDER_CONDITIONS_INX.

Regards

Uwe