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

Creating return orders

Former Member
0 Likes
1,096

Hi,

I am using BAPI BAPI_SALESORDER_CREATEFROMDAT2 to create sales orders. It works fine for order type 'OR' (all outbond orders) but when I use the same BAPI to create sales orders of order type 'RE' (return orders), it is giving error.

The error message is

"Unpermitted combination of business object BUS2032 and sales doc. category H "

Is there any another BAPI to create return orders or is there any parameter that I should set in the BAPI BAPI_SALESORDER_CREATEFROMDAT2 itself? I am using 4.7c version of SAP.

Please suggest me a solution.

Thanks,

Sonali.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
992

Creating return orders does not work with BAPI_SALESORDER_CREATEFROMDAT2. You need to use the BAPI BAPI_CUSTOMERRETURN_CREATE to create return orders.

Award points for helpfull answers.

4 REPLIES 4
Read only

Former Member
0 Likes
993

Creating return orders does not work with BAPI_SALESORDER_CREATEFROMDAT2. You need to use the BAPI BAPI_CUSTOMERRETURN_CREATE to create return orders.

Award points for helpfull answers.

Read only

0 Likes
992

Thank You Sudhir!

I think BAPI_CUSTOMERRETURN_CREATE may solve my problem.

Read only

Former Member
0 Likes
992

Hi,

Use the BAPI BAPI_SALESDOCU_CREATEFROMDATA1 for the return orders and for the normal orders..

Thanks,

Naren

Read only

Former Member
0 Likes
992

Hi Sonali,

By seeing your error messgaes it seems that sales document type is <b>returns (category H)</b>.

To my knowledge th BAPI BAPI_SALESORDER_CREATEFROMDAT2 you are using is correct. Make sure that you are giving the value of the parameter ORDER_HEADER_IN : DOC_TYPE as RE.

Also go through the links hope helpful...

http://help.sap.com/saphelp_47x200/helpdata/en/dd/55fb06545a11d1a7020000e829fd11/content.htm

http://help.sap.com/saphelp_47x200/helpdata/en/cc/ac79fa1cfe11d5809d000102a9aa8b/frameset.htm

Regards,

Azaz Ali.

Message was edited by: Azaz Ali