Application Development 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: 

BAPI_GOODSMVT_CREATE - Error

Former Member
0 Kudos
1,002

Hi,

I'm working arround BAPI_GOODSMVT_CREATE to create a 122 Movement ( Return to Vendor )

I was reading arround, a lot of people couldn't do it, but some of them claimed that they could find the solution.

Here goes my coding:

DATA: l_goodsmvt_header TYPE bapi2017_gm_head_01.

DATA: lt_mseg TYPE STANDARD TABLE OF mseg.

FIELD-SYMBOLS: -lfimg.

ls_goodsmvt_item-mvt_ind = 'B'.

APPEND ls_goodsmvt_item TO lt_goodsmvt_item.

CLEAR ls_goodsmvt_item.

ENDLOOP.

  • MATERIAL

CALL FUNCTION 'BAPI_GOODSMVT_CREATE'

EXPORTING

goodsmvt_header = l_goodsmvt_header

goodsmvt_code = l_good_mvt_code

  • TESTRUN = ' '

  • GOODSMVT_REF_EWM =

IMPORTING

goodsmvt_headret = l_goodsmvt_headret

materialdocument = l_materialdocument

matdocumentyear = l_matdocumentyear

TABLES

goodsmvt_item = lt_goodsmvt_item

  • GOODSMVT_SERIALNUMBER =

return = lt_return

  • GOODSMVT_SERV_PART_DATA =

  • EXTENSIONIN =

.

It goes referenced on the head to the mblnr that made the Outbound for the costumer.

Everything is ok, but for the items it returns this error code:

ID - M7

MSG - 21

LO Livre utilização não atingido em 1,889 T : 101 321F 0006 4B6343411

Any guess ?

Thanks !

1 ACCEPTED SOLUTION

Former Member
0 Kudos
184

Are you sure this is an error? It looks like an information (or possibly a warning) message to me. Have you checked the long text?

Is the goods movement created?

Rob

7 REPLIES 7

Former Member
0 Kudos
185

Are you sure this is an error? It looks like an information (or possibly a warning) message to me. Have you checked the long text?

Is the goods movement created?

Rob

0 Kudos
184

Hi Rob, thanks for your reply.

The document is not created. Its actually an error, something about there is no stock.

I'm referencing the header to another material document ( the one that goes to the customer ).

But the items, are referenced to a Request ( I'm not quite shure about the term in english, the system is portuguese. Number 45343379 )

And the error is something about charg(field) that has no stock, but this is a customer return.

And it let's the first item go through, but the rest comes back with that error.

I can do it without any problem on the transaction (migo).

I keep on tracking, but I can't see anything wrong.

Former Member
0 Kudos
184

The Message 021(M7) is "Deficit of & & & &". Check if you have deficit of the Material.

0 Kudos
184

Hi Suman, thanks for the reply.

But no, its a return to the vendor movement(122).

I can do it without any problem on the transaction migo.

aromalr
Active Participant
0 Kudos
184

Hi,

Post the same data though the corresponding t-code(MIGO).You could easily figure out the issue.

Regards

Aromal

Former Member
0 Kudos
184

Hi Aromal, thanks for the help, but unfortunately yes, I can do it on migo without any problem.

Former Member
0 Kudos
184

I got through the error from ID - M7 and MSG - 21. But then I got another error that is very odd ..

I've been reading on other forum posts that some people had the same odd behaviour.

It accepts the first item, but the rest it says the Quantity in EM ( Goods Inbound in english i think ) is not fulfill in 1,927 ( Strange number as weel.).

I gave him 2 items, they are both the same material number, the diference is the CHARG and the LFIMG.

Is it something about the same material ? Cause if i gave him one at each time, it does not have any problem .. 😕

Any help would be nice.

Thanks.