‎2008 Dec 05 6:07 AM
Hi,
How to update t.code VA02 from internal table data.
For each sales order the kbetr is changng based on exchange rate so it has to update in the VA02.
I prepared report and final data is inthe internal table and internal table with two fields i.e kbetr and kchel.
this two values has to update in va02 n they are running the report.
Thanks,
srii.
‎2008 Dec 05 6:22 AM
Hi,
I think your requirement is to update the condition values KBETR for the Condition types of the items in Sales order.
You can use the FM BAPI_SALESORDER_CHANGE.
use the table parameters ORDER_ITEM_IN, ORDER_ITEM_INX, CONDITIONS_IN, CONDITIONS_INX along with the import parameter(header details)
With Regards,
Dwarakanath.S
‎2008 Dec 05 6:59 AM
Hi,
Yes i want to update the condtion values for condition types of the items for sales order.
I'm using FM BAPI_SALESORDER_CHANGE. but i have to update to condtion type(Z02 & Z03)
while doing at a time two sales orders only second sales order condtion values are updation for both the sales orders.
Please help me on this,
Thanks,
srii.
‎2008 Dec 05 7:37 AM
Hi,
you need to call the FM BAPI_SALESORDER_CHANGE for one sales order data at a time.
In the internal table IT_SALES you have to get the sales order header and item data
For example with sales order number VBELN as the first field.
loop at it_sales into wa_sales.
wa_sales_temp = wa_sales.
at new vbeln.
fill header structures.
endat.
fill table parameters.
at end vbeln.
call function BAPI_SALESORDER_CHANGE.
if successful
call function BAPI_TRANSACTION_COMMIT.
endif.
refresh parameters passed to BAPI_SALESORDER_CHANGE.
endat.
endloop.
‎2008 Dec 16 7:41 AM