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_PO_CHANGE change two fields simultaneously

former_member537489
Participant
0 Likes
672

Hi,

I am having a problem with BAPI_PO_CHANGE and I was wondering if anyone can help me.

I am trying to use this BAPI to change the plant of a specific line of a purchase order, and at the same time, change the WBS element.

The problem is that old (existing) WBS element belongs to the old plant, so it gives me an error message before it changes the WBS element as well, so is seems that the BAPI does not do both jobs simultaneously.

For now, I overcome the problem by performing a batch input in me22n screen, but it is extremely slow, so I would appreciate any help on this.

Is there any way to make this BAPI perform two tasks together?

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
587

is there a way u can make the call to the BAPI twice...in the first call change the independant field and then change the dependant field in the next call.

hope this helps..

4 REPLIES 4
Read only

Former Member
0 Likes
588

is there a way u can make the call to the BAPI twice...in the first call change the independant field and then change the dependant field in the next call.

hope this helps..

Read only

0 Likes
587

Dear Sanket,

Thanks for your responce. I already tried to call the Bapi twice, but the problem is that the one field change is linked to the other, so each one of them , on their own ends in error. To be more specific, I am changing "werks" of a line item , and its wbs element. If I change werks first, then an error occurs on the old wbs element belonging to the old werks, and so on.

I would appreciate any ideas.

Read only

0 Likes
587

Perhaps you could avoid a COMMIT WORK between the 2 changes? For the system they both change at once then.

Read only

0 Likes
587

I tried that but unfortunately it didn't work. Same result. I will also notify the OSS.

Thnak you for your help.