Code: Alles auswählen.
REPORT ZTEST1.
TABLES: bapivbeln, bapisdh1, bapisdh1x, bapisdls.
DATA: i_item TYPE TABLE OF bapisditm,
lt_item TYPE TABLE OF bapisditm,
ls_item LIKE LINE OF i_item,
lt_item_inx TYPE TABLE OF bapisditmx,
ls_item_inx LIKE LINE OF lt_item_inx,
lt_return TYPE TABLE OF bapiret2,
ls_return LIKE LINE OF lt_return,
ls_head_inx TYPE bapisdh1x.
ls_head_inx-updateflag = 'U'.
bapisdls-pricing = 'C'.
ls_item-itm_number = '70'.
ls_item-price_date = '20190101'.
APPEND ls_item TO lt_item.
ls_item_inx-itm_number = '70'.
ls_item_inx-updateflag = 'U'.
ls_item_inx-price_date = 'X'.
APPEND ls_item_inx TO lt_item_inx.
CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
EXPORTING
salesdocument = '410005425'
order_header_inx = ls_head_inx
logic_switch = bapisdls
TABLES
return = lt_return
order_item_in = lt_item
order_item_inx = lt_item_inx.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
* EXPORTING
* WAIT =
* IMPORTING
* RETUR
.
Code: Alles auswählen.
data(order) = conv vbeln( |{ '410005426' alpha = in }| ).
Danke für die schnelle Hilfe.