2008 Jul 29 12:34 AM
I need to create return order (va01->create order with reference to ->billing document) from given invoice number.
Can someone please help me on what input table/parameter need to be filled out in BAPI 'BAPI_CUSTOMERRETURN_CREATE'?
And brief idea about how to create the parameter for the BAPI from the given billing document?
Eg: Do we need to read all order creation inputs from the billing document sales order? Or BAPI will do this logic if we give invoice number as input?
Thanks in advance.
2008 Jul 29 7:00 AM
I need to create return order (va01->create order with reference to ->billing document) from given invoice number.
Can someone please help me on what input table/parameter need to be filled out in BAPI 'BAPI_CUSTOMERRETURN_CREATE'?
And brief idea about how to create the parameter for the BAPI from the given billing document?
Eg: Do we need to read all order creation inputs from the billing document sales order? Or BAPI will do this logic if we give invoice number as input?
Thanks in advance.
2008 Jul 29 6:54 AM
2008 Jul 29 7:00 AM
2008 Jul 29 10:16 AM
Hi,
Check this one
Hi,
For Return Orders you may to use the BAPI:
You may have to populate below items.
CALL FUNCTION 'BAPI_CUSTOMERRETURN_CREATE'
EXPORTING
SALESDOCUMENTIN =
RETURN_HEADER_IN = lst_header_in
RETURN_HEADER_INX = lst_header_inx
SENDER =
BINARY_RELATIONSHIPTYPE =
INT_NUMBER_ASSIGNMENT =
BEHAVE_WHEN_ERROR =
LOGIC_SWITCH =
TESTRUN =
CONVERT = ' '
IMPORTING
SALESDOCUMENT = l_babi_vbeln
TABLES
RETURN = ltbl_return
RETURN_ITEMS_IN = tbl_items
RETURN_ITEMS_INX = ltbl_items_inx
RETURN_PARTNERS = tbl_partners
RETURN_SCHEDULES_IN = tbl_schedule_in
RETURN_SCHEDULES_INX = ltbl_schedule_inx
RETURN_CONDITIONS_IN =
RETURN_CFGS_REF =
RETURN_CFGS_INST =
RETURN_CFGS_PART_OF =
RETURN_CFGS_VALUE =
RETURN_CFGS_BLOB =
RETURN_CFGS_VK =
RETURN_CFGS_REFINST =
RETURN_TEXT =
RETURN_KEYS =
EXTENSIONIN =
PARTNERADDRESSES =
2008 Jul 31 2:26 PM
Just wanted to update all:
I need the reference billing (and its sales order details) to be copied in new sales order.
Following BAPI worked for me. Thanks for your input.
CALL FUNCTION 'BAPI_SALESDOCUMENT_COPY'
EXPORTING
salesdocument = lv_billing_document
documenttype = lv_new_sales_ord_type
IMPORTING
salesdocument_ex = lv_vbeln.
Note:
Input: billing document number
new sales order type
Output: new sales order created.
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |