Skip to Content
author's profile photo Former Member
Former Member

Unable to create material document with BAPI_GOODSMVT_CREATE

Hi all,

i am unable to create a material document instead an inbound delivery is getting created by this BAPI. the movement type is 501.

(the requirement is to create stock at a temporary storage location).

Please help me with this.

Thanks

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Apr 24, 2012 at 08:10 AM

    see the following example

    goodsmvt_item-material = VALDATAC_Z1-matnr.
    goodsmvt_item-plant = VALDATAC_Z1-werks.
    goodsmvt_item-stge_loc = VALDATAC_Z1-lgort.
    goodsmvt_item-batch = VALDATAC_Z1-charg.
    goodsmvt_item-move_type = '501'.
    goodsmvt_item-val_type = VALDATAC_Z1-charg.
    goodsmvt_item-entry_qnt = VALDATAC_Z1-clabs.
    goodsmvt_item-entry_uom = VALDATAC_Z1-meins.
    goodsmvt_item-move_mat = VALDATAC_Z1-matnr.
    goodsmvt_item-move_plant = VALDATAC_Z1-werks.
    goodsmvt_item-move_stloc = VALDATAC_Z1-lgort.
    goodsmvt_item-move_batch = '0000'.
    goodsmvt_item-move_val_type = '0000'.
    append goodsmvt_item.

    call function 'BAPI_GOODSMVT_CREATE'
    exporting
    goodsmvt_header = goodsmvt_header
    goodsmvt_code = goodsmvt_code
    * TESTRUN = ' '
    importing
    MATDOCUMENTYEAR = MATDOCUMENTYEAR
    materialdocument = materialdocument
    tables
    goodsmvt_item = goodsmvt_item
    return = msg.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Apr 23, 2012 at 06:29 PM

    I want to re-create MB1C......the goodsmvt_code passed is '05'...

    Thanks

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Apr 24, 2012 at 07:13 AM

    Hi Kartik,

    I have used this BAPI for other Goods movements but not for 501 and it always worked as it should.

    I suggest you to first try creating material document manually using MB1C tcode.

    If it is created successfully there, note down all the inputs passed in transaction and pass the same to BAPI.

    Also suggest you to read the documentation for this BAPI to get any helpful insights.

    Regards,

    SG

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.