‎2008 Feb 18 1:00 PM
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
‎2008 Feb 18 1:19 PM
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.
‎2008 Feb 19 1:58 AM
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