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_ALM_ORDER_MAINTAIN' on error. What's wrong ?

Former Member
0 Likes
1,409

Hello,

I would only change the "description" text on the header of service order.

I'm uising this bapi with these parameter, but I got this error:

IWO_BAPI2 118: Impossible to save the order because no one operation managed.

Why this error, I dant have to manage operation !!!

Any idea ?

  • Changement text de l'ordre - start

CLEAR it_methods.

REFRESH it_methods.

it_methods-refnumber = '1'.

it_methods-objecttype = 'HEADER'.

it_methods-method = 'CHANGE'.

it_methods-objectkey = w_aufnr.

APPEND it_methods.

it_methods-objecttype = space.

it_methods-refnumber = '2'.

it_methods-method = 'SAVE'.

APPEND it_methods.

REFRESH: it_header, it_header_up.

CLEAR it_header.

it_header-short_text = 'ubaldr test'.

it_header-orderid = w_aufnr.

APPEND it_header.

it_header_up-orderid = w_aufnr.

it_header_up-short_text = 'X'.

APPEND it_header_up.

CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'

TABLES

it_methods = it_methods

it_header = it_header

it_header_up = it_header_up

return = it_return_os2.

commit etc etc

Tks.

Hello,

I would only change the "description" text on the header of service order.

I'm uising this bapi with these parameter, but I got this error:

IWO_BAPI2 118: Impossible to save the order because no one operation managed.

Why this error, I dant have to manage operation !!!

Any idea ?

  • Changement text de l'ordre - start

CLEAR it_methods.

REFRESH it_methods.

it_methods-refnumber = '1'.

it_methods-objecttype = 'HEADER'.

it_methods-method = 'CHANGE'.

it_methods-objectkey = w_aufnr.

APPEND it_methods.

it_methods-objecttype = space.

it_methods-refnumber = '2'.

it_methods-method = 'SAVE'.

APPEND it_methods.

REFRESH: it_header, it_header_up.

CLEAR it_header.

it_header-short_text = 'ubaldr test'.

it_header-orderid = w_aufnr.

APPEND it_header.

it_header_up-orderid = w_aufnr.

it_header_up-short_text = 'X'.

APPEND it_header_up.

CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'

TABLES

it_methods = it_methods

it_header = it_header

it_header_up = it_header_up

return = it_return_os2.

commit etc etc

Tks.

4 REPLIES 4
Read only

kesavadas_thekkillath
Active Contributor
0 Likes
1,010

Ignore

Edited by: Keshav.T on Aug 4, 2010 8:01 PM

Read only

0 Likes
1,010

With this:

CLEAR it_methods.

REFRESH it_methods.

it_methods-objecttype = space.

it_methods-refnumber = '1'.

it_methods-method = 'SAVE'.

APPEND it_methods.

CLEAR it_methods.

it_methods-refnumber = '2'.

it_methods-objecttype = 'HEADER'.

it_methods-method = 'CHANGE'.

it_methods-objectkey = w_aufnr.

APPEND it_methods.

REFRESH: it_header, it_header_up.

CLEAR it_header.

it_header-short_text = 'ubaldr test'.

it_header-orderid = w_aufnr.

  • it_header-order_type = 'CS02'.

  • it_header-planplant = 'CIMO'.

  • it_header-plant = 'CIMO'.

    • it_header-equipment = w_bzgsobj. "'CITMOB' "T399A

  • it_header-material = it_order_items_in-material.

APPEND it_header.

it_header_up-orderid = w_aufnr.

it_header_up-short_text = 'X'.

APPEND it_header_up.

CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'

TABLES

it_methods = it_methods

it_header = it_header

it_header_up = it_header_up

return = it_return_os2.

now the error is:

on the 2° entry of the header table, the method change dont found !!

Any idea ?

Read only

0 Likes
1,010

Hey,

Go with your first approach.

Do not pass any refnumber to SAVE line in methods table.

try it once.

it_methods-objecttype = space.

it_methods-refnumber = '2'.

it_methods-method = 'SAVE'.

APPEND it_methods.

shravan

Read only

0 Likes
1,010

Hello ,

thank you for your reply:

The reason of error was that user name using this MF have not all authorization to create a sales order.

Regards,

Roberto.