cancel
Showing results for 
Search instead for 
Did you mean: 

Order creation error in BAPI_ALM_ORDER_MAINTAIN function module

Former Member

Dear Experts,

While creating Service order by using BAPI_ALM_ORDER_MAINTAIN function module, getting below return parameters

IWO_BAPI2 103 Method SAVE is not provided for object PARTNER

IWO_BAPI2 119 BAPI call must have a SAVE or DIALOG method

Please suggest me.

Thanks & Regards

Prashanth

Accepted Solutions (0)

Answers (2)

Answers (2)

peter_atkin
Active Contributor
0 Kudos

Here's some test code for changing operations:

*&---------------------------------------------------------------------*
*& Report  ZPJA0008                                                    *
*&---------------------------------------------------------------------*
*& BAPI_ALM_ORDER_MAINTAIN Test                                        *
*&---------------------------------------------------------------------*
report zpja0008.

data : methods      type standard table of bapi_alm_order_method,
         operations type standard table of bapi_alm_order_operation,
         zreturn    type standard table of bapiret2.

data : xmethod     like bapi_alm_order_method,
       xoperations like bapi_alm_order_operation,
       xaufnr      like aufk-aufnr,
       xreturn     like bapiret2.

xoperations-activity               = '0010'.
xoperations-constraint_type_finish = '3'.
xoperations-FIN_CONSTR             = sy-datum.
xoperations-description            = 'OP10A'.
append xoperations to operations.

xoperations-activity               = '0030'.
xoperations-constraint_type_finish = '2'.
xoperations-description            = 'OP30A'.
append xoperations to operations.

refresh: methods.

xaufnr = '000004000497'.

clear: xmethod, xoperations.

xmethod-refnumber     = 1.
xmethod-objecttype    = 'OPERATION'.
xmethod-method        = 'CHANGE'.
xmethod-objectkey(12) = xaufnr.
append xmethod to methods.

xmethod-refnumber     = 2.
xmethod-objecttype    = 'OPERATION'.
xmethod-method        = 'CHANGE'.
xmethod-objectkey(12) = xaufnr.
append xmethod to methods.

clear xmethod.
xmethod-refnumber     = 1.
xmethod-method        = 'SAVE'.
xmethod-objectkey(12) = xaufnr.
append xmethod to methods.

call function 'BAPI_ALM_ORDER_MAINTAIN'
  tables
    it_methods   = methods
    it_operation = operations
    return       = zreturn.

call function 'BAPI_TRANSACTION_COMMIT'.
NTeunckens
Active Contributor
0 Kudos

Please provide your coding on the BAPI-logic ... This will give us a better clue as to what is happening ...