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

Capturing Failed Goods Movements while using BAPI_GOODSMVT_CREATE

Former Member
0 Likes
2,235

Hello,

Is there any parameter in BAPI_GOODSMVT_CREATE that tells the program to capture the failed goods movements so that those are visible in COGI?

If not then does a standard BAPI exists that can help in recording the failed goods movements?

Even though there are numerous postings on the BAPI itself but I could not find something relevant to this issue.

Thanks

Udayan

15 REPLIES 15
Read only

Former Member
0 Likes
2,043

Guys anything?

Read only

tarangini_katta
Active Contributor
0 Likes
2,043

Hi,

Are you not getting the failed documents to the tables parameter Return.

Thanks

Read only

0 Likes
2,043

You mean if I am getting back anything in RETURN?Yes I am.

But that is just the returned error which (I think) does not ensure that the failed goods movement is captured in the SAP Database so that it is visible in COGI.

I am not an ABAPER so I may be wrong but maybe I am missing something.

Help me out if you can.

Thanks

Read only

0 Likes
2,043

Normally, I use the return table and capture the error messages there. I am assuming that you should see the same errors in COGI?

Read only

0 Likes
2,043

That is what the problem is. I do not see the errors in COGI.

I can read the RETURN table for the errors and display the same on my Web Application but what I am trying to find out is whether the BAPI automatically would record the failed goods movements/errors for the display in COGI.

Do you know if I am missing something in my BAPi usage or whether there is another way to accomplish this .

Thanks

Read only

0 Likes
2,043

Usually whatever messages exist in the return table are the critical ones. However, some may only be informational.

What errors are you seeing in the return table? Are they errors or warnings? Does the Goods Movement look OK in SAP? Have you checked transactions. Why do you think there is a problem if COGI does not reflect any issues?

Read only

0 Likes
2,043

I am looking at the usual errors in RETURN and yes these are errors not warnings.

For example: Material <xxxxx> does not exist for <plant><storage loc><valuation type>. ....

As you would know the one of the benefits(or probably the only one..) of COGI is that it lists failed goods movements which can be corrected at a later point in time by, lets say a supervisor.

In my case the web application is being used by technicians and if a goods movement fails they do not have a work around to fix that.

I was hoping that if these get recorded in COGI then one would have a record of failed goods movements which eventually can be fixed.

Makes sense?

Now, as I have observed so far that the goods mvt BAPI does not take care of this and was hoping to find some other solution within SAP itself.

If not then I will have to look at something else.

Let me know if you have any ideas.

Thanks for the help so far.

Read only

0 Likes
2,043

What errors are you getting in the return table. They may not justify being put in COGI?

Read only

0 Likes
2,043

I guess I need to tell you more.

These are Goods Issued against a Work Order (movement 261) and as far as I know,any goods movement error tied to an order , if you are executing the transaction from withing R/3, must be logged in COGI.

But as I mentioned earlier , I am not an ABAPER and know very little about SAP config so I may be wrong.

As for an error :

Deficit of SL Unrestricted-use 4 EA : <Mat Num><Plant><Storage loc>

Here I was trying to issue 4 eaches of this material but in actuallity the qty was reserved for another order so it came back with this error.

Now when i try to issue this material from within SAP (I use trx IW42) the goods movement error is captured in COGI but not when you try to issue the same using the Web App.

Thanks

Read only

0 Likes
2,043

Udayan, This is a functional task then, not an ABAP issue. Is someone there familiar with transaction SPRO, then SAP Reference Image. Seems to me some config may be left to do in that environment. I am not familiar with those settings. But I would assume that if your return table is getting those kinds of errors something may need to be setup in config. Or, you may be right that a parameter may need to be set in the FM. Is there a parameter available that would allude to sending this data to COGI?

Read only

0 Likes
2,043

Is there a parameter available that would allude to sending this data to COGI?

Yea that is what I am trying to find out but no luck so far.

As for the functional I'll see if I can get any help.

I appreciate you patient listening on this issue.

Thanks

Read only

0 Likes
2,043

Hello Udayan,

it is not possible at all to create COGI records using BAPI_GOODSMVT_CREATE.

You may think about using the work order confirmation BAPI, entering a kind of dummy confirmation with 0 qty and using the goods movement table of that BAPI for your posting. Failed goods movements of any confirmation BAPI (production, process, maintenance or network order) will be stored in COGI.

Regards, Andreas

Read only

0 Likes
2,043

Thanks Andreas.

You are right and I was hoping to do the same because in my previous experience I had come accross process order confirmations and the BAPIs do have a GM table but unfortunately this is not the case with BAPI_ALM_CONF_CREATE.

I am very sure that there is no standard way that one can accomplish this. Do let me know if you do.

Regards.

Read only

0 Likes
2,043

Hello Udayan,

you're right. I was sure that this has been developed in the meantime also for the maintenance BAPIs but unfortunatly it was not.

So there is no way in standard...

Regards, Andreas

Read only

0 Likes
2,043

This message was moderated.