Application Development 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: 

Require BAPI or FM to create Sales Order with Serial Number information

0 Kudos

Hi All,

We have a requirement to Create Sales Order with the Serial number information.

We have following BAPI's but they does not handel the Serial number information.

BAPI_SALESORDER_CREATEFROMDAT1

BAPI_SALESORDER_CREATEFROMDAT2

BAPI_SALESDOCU_CREATEFROMDATA.

Please suggest us the BAPI or FM to handle the requirement.

Regards

Mahadev Divekar

+91 9422536357

2 REPLIES 2

Former Member
0 Kudos

Hi,

These standard BAPIs wont help you out in cases where you have more customised creation of SO. I would suggest in creating a new RFC Function module which would work based on a BDC.

It would be faster for you to create and test, compatible in case of any upgrades and you will also not have to deal with Commit which is not available in the ones you have mentioned.

Thanks and Regards,

Arnab

former_member246953
Discoverer
0 Kudos

Hello,

We have a similar requirement where the sales order is created in ERP through CRM. Basically it concerns a CRM inhouse order that is replicated to ERP where it is handled logistically (outbound return delivery and so on).

In ERP this is created through a CRM specific BAPI BAPI_SALESDOCU_PROXY_UPLOAD.  This BAPI does not allow to pass on the SN either.

What we did (draft version that still needs some extensive testing):

- we give along the serial information in TI_EXTENSIONIN (table of structure BAPIPAREX). I assume that the other SD BAPI's have the same EXTENSION table in the function signature.

- we implemented an implicite enhancement at the start of BAPI_SALESDOCU_PROXY_UPLOAD to store this extension data in the global data of a new function group. The standard EXTENSION handling only allows some specific strucures to be handled.

- in the SD exit USEREXIT_SAVE_DOCUMENT_PREPARE we then use function modules SERNR_ADD_TO_AU and SERIAL_LISTE_POST_AU to link the SN's to the item. We also update ANZSN in FXVBAP. We get the relevant SN's from the global data of our new function group.

It appears to function correctly. The SN is updated in the sales document item as a technical object.

I hope it helps you all who are looking to find a BAPI that can handle technical objects....