BAPI_GOODSMVT_CREATE for GRN against GI material document in STO

Dear experts,
Please advice me how to use BAPI_GOODSMVT_CREATE for goods receipt against GI material document (351) in the case of UB stock transport order.
My requirement is to get the 101 document no. range in 49 series.
When i use GM code 01 then PO is must.
Please advise me which GM code/ Mov indicatot/ reference fields touse.
Or else to use any other BAPI.
sapmmlearner

please share ur thoughts....

Similar Messages

  • Unable to create excise invoice against the Material document

    Hi experts,
    Unable to create excise invoice against the Material document in J1IEX transaction.
    Material document is generated through quality management which movement type is 105.
    error message :
    Material document cannot be processed
    Message no. M7130
    Thanks
    SAP MM

    Steps to do GR along with excise,
    1.Capture excise invoice using J1IEX.
    2. Refer excise invoice no. in MIGO(SAP not recommends to post excise invoice against 105 mvmt against blocked stock)
    3. Post excise invoice using J1IEX

  • BAPI_GOODSMVT_CREATE - Error while posting a Material Document

    Hi Experts,
    We are  trying to do the material document posting using the transaction "MB1C" manually in SAP. The movement type which we are using for the same is "261".  While doing this is, it is asking for a work order number and the Recipient number. We gave the Recipient Number as "123". Material document is created successfully.
    Again using the same transaction  "MB1C" , we are trying to do the reversal of the material document which we posted previously against another work order number for the same material and the serial number if the material is serialised and as well as for the non serialised material.
    Both this case, in SAP the material document is created succesfully. This is done manually in SAP.
    When we are trying to create the material document using the BAPI 'BAPI_GOODSMVT_CREATE', for the above scenario, posting the material document '261' movement type for one work order and the reversal for another work order '262' movement type for the same material (whether it is a serialised or non serialised) we are getting the eror as "RE Qty. transferred exceeded 1 PC: 50,003,695 C001 USED 1200".
    We are passing the following at the item level. MATERIAL Number, Plant, STGE_LOC, ENTRY_QNT, MOVE_TYPE, BATCH, ORDERID, RESERV_NO,  RES_ITEM, ACTIVITY, XSTOB for reversal.
    We are passing the GM_CODE as '05'.
    Please let us know what needs to be changed inorder to create the material document properly without getting errors.
    Thanks in Advance,
    Mohan.

    Hi,
    We fixed this issue by removing the reservation number of the material when we are trying to post the material document with the movement type "262".
    The reason for removing the reservation number for the movement type "262"
    The reservation number is getting created against a work order when we trying to create the work order in IW32. This reservation number is used for validating the stock while we are trying to consume and doing the reversal.
    SAP is allowing us to reverse the consumed quantities only based on the reservartion number and hence we got this error.
    To fix this error, if we are trying to reverse a particular material against a different work order for which it has been consumed previiously, remove the reservation number and item number and try posting the material document.
    Hope this solution will solve your issue:)
    Thanks and Regards,
    Mohan.

  • BAPI_GOODSMVT_CREATE for GRN posting

    Hi Experts,
    I am using BAPI_GOODSMVT_CREATE for posting GRN against Purchase Order.
    I want to post Quantity in Delivery note(LSMNG) and Unit of Measure From Delivery Note(LSMEH) also.
    I used itab-QUANTITY = '1'.
    itab-BASE_UOM = 'L'.
    but it is not getting updated properly.
    I am getting document number and GRN has been done against Purchase Order using this BAPI.All other fields are properly getting updated except these 2 fields Qty in delivery note and unit of delivery note. Can i pass these 2 field values using this BAPI or do I need to use any other BAPI. Is there any BAPI for MIGO instead of MB01?
    Can any one help me to pass these values through BAPI
    Regards,
    Sam

    Hi,
    you can update LSMNG quantity using EXTENSIONIN structures of BAPI_GOODSMVT_CREATE.
    The steps are the following:
    Add LSMNG field in BAPI_TE_XMSEG structure create an appending structure (char field)
    By SE19 transaction create the Enhancement Spot starting from MB_GOODSMOVEMENT
    Define the Badi Implementation choosing MB_BAPI_GOODSMVT_CREATE Badi Definition implementing a new customer class.
    Remember to choose to copy the class with the source code of methods.
    In The method IF_EX_MB_Hi, you can update LSMNG quantity using EXTENSIONIN structures of BAPI_GOODSMVT_CREATE. The steps are the following: Add LSMNG field in BAPI_TE_XMSEG structure create an appending structure (char field) By SE19 transaction create the Enhancement Spot starting from MB_GOODSMOVEMENT Define the Badi Implementation choosing MB_BAPI_GOODSMVT_CREATE Badi Definition implementing a new customer class.
    Remember to choose to copy the class with the source code of methods.
    In the method IF_EX_MB_BAPI_GOODSMVT_CREATE~EXTENSIONIN_TO_MATDOC you will find the following source code:
      DATA:     c_lenstruc          TYPE i VALUE 30,    
       wa_bapi_mb_header   TYPE bapi_te_xmkpf,    
       wa_bapi_mb_item     TYPE bapi_te_xmseg,    
       wa_extension_in     TYPE bapiparex.  
       FIELD-SYMBOLS:               TYPE imseg.  
       CHECK NOT extension_in[] IS INITIAL.
      * Analyze IMSEG for document structure and assign LINE_IDs if necessary  
       CALL METHOD cl_mmim_line_id_manager=>analyze_mb_create    
              CHANGING       ct_imseg          = ct_imseg[]    
                 EXCEPTIONS       duplicate_line_id = 1      
                 OTHERS            = 2.  
      LOOP AT extension_in INTO wa_extension_in.    
         CASE wa_extension_in-structure.
    * extension of MKPF      
         WHEN 'BAPI_TE_XMKPF'.        
         MOVE wa_extension_in+c_lenstruc TO wa_bapi_mb_header.        
         MOVE-CORRESPONDING wa_bapi_mb_header TO cs_imkpf.
    * extension of MSEG      
        WHEN 'BAPI_TE_XMSEG'.        
        MOVE wa_extension_in+c_lenstruc TO wa_bapi_mb_item.        
        READ TABLE ct_imseg           WITH KEY line_id = wa_bapi_mb_item-matdoc_itm           ASSIGNING   <fs_imseg>.        
          IF sy-subrc EQ 0.          
             MOVE-CORRESPONDING wa_bapi_mb_item TO   <fs_imseg>.       
           ENDIF.   
         ENDCASE.  
        ENDLOOP.
    Then you have to call BAPI_GOODSMVT_CREATE using extensionin in the following way:
    * Fill   goodsmvt_header structures
      goodsmvt_header-........
    * Fill    goodsmvt_item-position
      Loop at it_position.
             goodsmvt_item-..........
              wf_line_id = wf_line_id + 1.
              goodsmvt_item-line_id = wf_line_id.
              APPEND goodsmvt_item.
            CLEAR extensionin.
            MOVE 'BAPI_TE_XMSEG'    TO extensionin-structure.
            MOVE wf_line_id+2(4)    TO extensionin-valuepart1+14(4).
            MOVE LSMNG              TO extensionin-valuepart1+18(16).
            APPEND extensionin.
    endloop.
            CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
            EXPORTING
              goodsmvt_header               = goodsmvt_header
              goodsmvt_code                 = goodsmvt_code
    *         TESTRUN                       = ' '
              goodsmvt_ref_ewm              = goodsmvt_ref_ewm
            IMPORTING
    *         GOODSMVT_HEADRET              =
              materialdocument              = materialdocument
              matdocumentyear               = matdocumentyear
            TABLES
              goodsmvt_item                 = goodsmvt_item
    *         GOODSMVT_SERIALNUMBER         =
              return                        = return
              extensionin                   = extensionin.
    Hope it helps
    Lorenzo

  • MIGO for GRN against Outbound delivery

    Hi,
    I have a requirement for creation of GRN against outbound delivery using MICO tcode, i have used the FM 'BAPI_GOODSMVT_CREATE but in table T158G for MIGO tcode there is no number assigned in our system landscape as it is std table, but respectively (MB01,MB31,etc no's are there) how to create number for MIGO in table T158G and correspondingly Movement Indicator which should be used for Outbound delivery, please kindly sujjest me.
    Thanks in advance,
    Puneetraj.

    Hi
    No, I am not having any release procedure.
    Yes, I have picked the qty in VL02N
    In vendor master, I have assigned the supplying plant to vendor.
    Actually, i have created the plant as vendor and assigned it to itself.
    Its not a error message. plz see the message.
    Document 0080016192   does not contain any selectable items
    Message no. M7064
    Diagnosis
    The document or document item entered cannot be adopted.
    Possible reasons for this are:
    The document items have already been processed
    (Suggest zero lines indicator set?).
    the document items have been deleted or are blocked.
    the document items have been created for a different plant.
    (for reservations only) movements are not yet allowed for the reservation items.
    (for reservations only) the document items are retrograde components of the order. These are posted using the order confirmations.
    A confirmation must exist for the document items.
    The document items must be released first.
    The document is an R/2 document.
    Procedure
    Make sure your entries are correct.
    If the system has already processed the total quantity, you can set the Suggest zero lines indicator. The system will suggest the quantity zero for the items that have already been processed.
    If you have entered a particular item, cancel the item. If you do not enter an item, the system searches all of the open items in the document.
    If the document is a purchase order, production order or a reservation, you can enter search criteria in the dialog box.
    You access the dialog box by choosing Enter with reference on the initial screen.
    If the document is an SAP R/2 document, you have to cancel it manually by entering the reversal movement type.
    Regards
    Neeraj Kumar Jain

  • GR slip for PO created in Material document but not printed or in spool

    Hello Inventory Management Gurus,
    I have a problem printing GR slip onto the printer.
    I am able to create the output and can see in the material document but not in the spool or printer.
    I configured GR slip printing in OMJ4, created condition record in MN21 configured in NACE etc., for the output type.
    What is preventing from printing or appearing in the spool if it created the output in material document?
    I have the setting "print immediately" enabled and "release after output" unchecked in OMJ4.
    What is missing?
    Please help.
    George

    Hi
    Output for GR is Printed through T-code 'MB90".
    Note - in GRN  Individual /Collective Slip and Print indicator should be selected.
    Enter the GRN No,Select the Output type and Execute.
    Regards
    Viru

  • Please provide logic for schedule lines and material document Quantity.

    Hi ABAPers,
    Please help in the following context.
    Is there any connecting or refrence field for which a particular schedule line item are considerd for the goods reciept of a particular material document.
    Also provide the logic.
    19                    34
    15
    14                   35
    11
    10
    If 19 15 14 11 10 are schedule lines, and 34 35 are two recived quantities,
    Then how can be the possible permutations and combinations logic to find out that, 34 = 19 + 15 and
           35 = 141110.
    Thanks in advance...

    Niles Raut wrote:
    Hello Gurus,
    >
    > This is intracompany STO scenario with delivery. There is one STO for quantity say 1000 pc created in 2008. Delivery and PGI done for 1000 qty in 2008.  Goods are received in receiving plant for qty 1000 in 2008. Now this delivery document is archieved and user has reversed the GR material document in 2010. Now this reversal material docuemnt has zero material qty becasue the delivery was archieved(which is the probable reson)
    >
    > When I want to cancel this reversal material document it gives error that "Qty and / or "delivery completed" ind. or final issue ind. are missing" which is logical since material document has zero quantity.
    >
    > Is there any sap notes or any other way to fix this?
    >
    > Please guide.
    >
    > Regards
    > Nilesh
    Where is actually the problem, if one only reversed 0 quantity?
    Why do you think you need to reverse this reversal again?
    why with year 2010?
    Dont you do anual inventories?  Such stock counts have corrected your stock anyway. if you start cancelling older movements then you create stock inconsistencies again.

  • Report for GRn against PUR Order

    Dear All ,
    I want to see the All GRn against the Purchase order in a perticular month in a plant .
    which report i have to follow . Pl guide .
    Regards

    Hi,
    Go to transaction SE16N, enter the table name as EKBE and press enter.
    In the selections, please enter your PO no. and in the posting date field enter the from date and the to date of the period for which you want to see the GRs
    Press execute and you will have a list of GRs posted during the selected period for the PO.
    In case if you do not give the PO number in the selection, the data for all the POs shall be displayed.
    Regards,
    Gaurishankar

  • How to find Delivery numbers for a range of Material Documents

    Hi,
    Could anybody please let me know how to find the delivery numbers from a range of material documents based on a given delivery date.
    Regards
    Kasi

    Hi,
    there is an index table for deliveries by material:
    VLPMA
    Select the delivery numers using the material range from VLPMA.
    Regards,
    Clemens

  • User exit  for MIGO  after the material document is created?

    hi  guys ,
    I have requirement like after the   material document was creted in migo  i need to call my new transcation. can any one please let me know how  i have to solve this ?
    Moderator Message: Unfortunately, this is not a training forum and we can teach all about Exits and Badi's. I suggest you take a classroom course..... or do some R&D first
    Edited by: kishan P on Nov 30, 2010 11:57 AM

    Hi
    U need to create a FM with UPDATE MODULE attribute checked: so you fm can be run in UPDATE TASK
    This fm has to have the same interface of the method of the BAID (or user-exit) or a parte of it, if you don't need to use all parameters of the interface.
    All code to schedule the job has to be placed in this fm: you can use the fm JOB_OPEN and JOB_CLOSE in order to scheule a job programmatically.
    Call this fm in the BADI, the call has to be in UPDATE TASK, in this way your porgram can start as soon as all updating processes are over
    Max

  • Table for PO order and material document link

    Hello,
    I want to extract PO order and respecitive material documents ( IR , GR docs.)
    Can you give table(s) names ?
    Thanks,
    Ishak

    Hi ,
    You can use 2LIS_02_ITM ,2LIS_02_SCL DataSource you also check the following DataSources
    2LIS_02_SCL Tables EKKO, EKBE, T001, T001W, EKET, EKPA.
    2LIS_02_HDR  Tables  EKKO, EKBE, T001, EKPA.
    2LIS_02_ITM Tables  EKKO, EKBE, T001, T001W, EKPO, TMCLVBW, T027C, ESSR, T147K, T147
    2LIS_02_SCN  Tables  EKET, EKES, EKPO.
    2LIS_02_CGR  Tables  EKBE, EKES, EKPO.
    2LIS_02_SGR  Tables EKET, EKBE, KKPO
    Thanks
    REddy

  • Capture Excise Invoice for material document created against a PGR

    Hi SD Gurus,
    We have a scenario of reverse subcontracting where we have to receive raw material from vendor, process it and then dispatch the finished goods to the vendor or the vendor's customer.
    For receiving the raw materials, i have created a document type which is copied from standard RE type. Against this order, a returns delivery is created which is then PGR-ed. With reference to the previous document, a service order is created in SD, which is then billed.
    But i am facing a problem when i tried to capture the incoming excise invoice for the raw materials. When i tried to capture the excise against the material document generated for PGR, the system is throwing a error, that it cannot capture the excise for this materia document type.
    I would be greatly obliged if anyone can throw some light on this. Do i need to maintain any special configuration for this? Why is SAP not allowing it? How this can be done?
    With Regards,
    Arindam Datta.

    Dear Arun R,
    You Kindly go to the following path and maintain your movement type over their and do the MIGO.I am very sure at the time ot migo excise tab will come for part-1 updation and subsequently you capture part-2 on J1IEX.
    SPRO->LG->Tax on Goods Movemet->India->Business Transactions->Incoming Excise Invoice->Specify which movement type involve excise Invoices.
    Hope this will help you out.
    Regards
    AKS

  • Change "Reason for Movement" on Material Document

    I've posted a Material Document.  I now need to change the Reason for Movement.  I've tried this via MB02 but only the Goods Recipient and Text appear to be updatable.  Is it possible to change the Reason for Movement after the Material Document has been posted?  If so, how?

    Hello David,
    Except "text field" & "unloading Point", you can not modify any other field in Material document change mode (MB02 t-code)
    Hope this helps.
    Regards,
    Arif Mansuri
    Reward if answer is helpful.

  • Return Delivery of Material Document as in MIGO.

    Hi  guys,
    Is there any bapi or function  module that  simulates the Return Delivery of Material Document as done in MIGO transaction.
    I have checked BAPI_GOODSMVT_CREATE but, this is not exactly matching the Return Delivery process(i.e, therez no field for item number of material document although material document field exists in GOODSMVT_ITEM) . If there is an other bapi or function module, kindly suggest.
    Many thanks in advance.
    Nithin

    Hi Nithin,
    Check FM  <b>BAPI_GOODSMVT_CREATE</b> documentation. In that check this
    6. GM_Code 06: Reversal of goods movements.
    Regards,
    Balavardhan.K

  • CO27 : Item text in Created Material document

    Hi ,
    We are executing CO27 to pick material against Prodn orders / maintenance orders.
    I noticed Line Item Text (MESG-SGTXT) automatically gets updated with certain text (different from material desc) in material documents mtype 261 created from CO27.
    I am just wondering from where the TEXT is being picked.
    If I create a 261 document manually using MB1A , no text is being picked.
    Any idea from where this TEXT is picked in case of CO27.
    Regards
    Shrey

    Hi ,
    Could u pls help me to execute Co27 at my end also ..... here we are using picking list for "Maintenance orders".
    I checked one maintenance order against which material document was generated with text  . but surprizingly no components has been allocated to that orders.
    Therefore wondering how the PICKING LIST was processed against that ORDER for which no component was allocated.
    Could u pls let me know the step to replicate the process against same MAINTENANCE ORDER ?
    Regards
    Shrey

Maybe you are looking for

  • [CS3 JS] Finding paragraph containing table

    I have a table object and want to find the paragraph that contains the table. Then I want to return the contents of the paragraph previous to the table anchor. I am using this, but when I attempt to display the contents of the paragraph, I get "Objec

  • User not receiving email / corrupt database?

    Much like another recent post, I have a user that can not receive email the emails just sit in the queue. The error on those messages is "[[email protected]]: temporary failure" Here are the twists: 1) We had a power spike a couple of days ago. The u

  • Check reprint

    Hi Gurus, I have manually run the payment for vendor  using F-53 and using the payment document, was trying to create a check and got this msg "The check information alreay exists in check management" then I have created a new check lot and was able

  • My Firefox 5.0 does not support the latest Acrobat Reader. I went back to IE because of this. Is there a fix?

    I'm an Acrobat 8 user, and I have the latest version of Reader (checked--no updates are available). After a recent update to Reader, Firefox stopped supporting .pdf files. I tried updating to the latest Firefox version--5.0, but I still have the prob

  • Need a Help building Longer datatypes

    Hi Friends, I have a Complex problem right now. I am trying to build a longer datatypes of an unsinged interger where in we can specify the length of it where in we can specify number of bits required to store the data and is this is exceeding the lo