Skip to Content
0
Former Member
Dec 30, 2004 at 09:09 AM

BAPI_SALESORDER_CHANGE

66 Views

Hi Friends,

i am using BAPI_SALESORDER_CHANGE for updating sale order line item amount. I developed a code that is mentioned below. after executing contains of RETURN likeITEM_IN has been processed successfully

ORDER_HEADER_IN has been processed successfully

Warr/Emg Order-Parts 2010815 has been saved

but, it is not coming in SO. does anyone tell me where did i mistake

  • move itab_pso-vbeln to order_header_in-collect_no.

  • move itab_pso-vkorg to order_header_in-sales_org.

*

move 'U' to order_header_inx-updateflag.

  • move 'X' to order_header_inx-collect_no.

  • move 'X' to order_header_inx-sales_org.

move itab_pso-posnr to order_item_in-itm_number.

  • move itab_pso-pstyv to order_item_in-item_categ.

move itab_pso-kbetr_n to order_item_in-target_val.

append order_item_in.

move itab_pso-posnr to order_item_inx-itm_number.

move 'X' to order_item_inx-updateflag.

  • move 'X' to order_item_inx-item_categ.

move 'X' to order_item_inx-po_itm_no.

move 'X' to order_item_inx-target_val.

append order_item_inx.

CALL FUNCTION 'BAPI_SALESORDER_CHANGE'

EXPORTING

SALESDOCUMENT = itab_pso-vbeln

ORDER_HEADER_IN = order_header_in

ORDER_HEADER_INX = order_header_inx

  • SIMULATION =

  • BEHAVE_WHEN_ERROR = ' '

  • INT_NUMBER_ASSIGNMENT = ' '

  • LOGIC_SWITCH =

TABLES

RETURN = return

ORDER_ITEM_IN = order_item_in

ORDER_ITEM_INX = order_item_inx

  • PARTNERS =

  • PARTNERCHANGES =

  • PARTNERADDRESSES =

  • ORDER_CFGS_REF =

  • ORDER_CFGS_INST =

  • ORDER_CFGS_PART_OF =

  • ORDER_CFGS_VALUE =

  • ORDER_CFGS_BLOB =

  • ORDER_CFGS_VK =

  • ORDER_CFGS_REFINST =

  • SCHEDULE_LINES =

  • SCHEDULE_LINESX =

  • ORDER_TEXT =

  • ORDER_KEYS =

  • CONDITIONS_IN =

  • CONDITIONS_INX =

  • EXTENSIONIN =

.

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

EXPORTING

WAIT = 'X'

  • IMPORTING

  • RETURN =

.

Tnanks in advance,

Parag