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

BAPI_SALESORDER_CHANGE

Former Member
0 Likes
519

Hi

Is there any other BAPI /Function module to update the Service contracts other than BAPI_SALESORDER_CHANGE.

Because there is no document type in this BAPI...

Thanks in advance.

Regards,

Jayashree

2 REPLIES 2
Read only

Former Member
0 Likes
474

Hi,

Checking sy-subrc may not be always reliable as it can return values like .001 even if the transaction is successful

Best way to check this is to check for the success message in the message table.

All transactions give a success message if the transaction is successful. SAP guarantees that these message numbers wont change in any release of SAP.

First get the message number, id etc of the success message of the transaction you are trying to call, then check this message number and id in the message table that the call transaction returns. If you find the entry in the message table, the call transaction is successful.

Read only

Former Member
0 Likes
474

Check FM: SD_SALESDOCUMENT_CHANGE which is internally called in BAPI: BAPI_SALESORDER_CHANGE based on the business object.

Header structure is different in both FM's, apart from that you have the document type field which you are looking for.

Note Servive contracts can not be changed via BAPI_SALESORDER_CHANGE as the business object is different.

Just FYI, the FM is not released and incase you are looking specific for contracts you might consider BAPI: BAPI_CUSTOMERCONTRACT_CHANGE

Regards

Eswar