BATCH in Material Doc - MSEG-CHARG, BAPI_GOODSMVT_CREATE??

HI Experts,
I got a requirement like,
Threre is a item 10 of qty 5, in a delivery, its batch is BATCH SPLIT.
I need to create a material document from this delivery/item.
So, currently material doc is creating via BAPI_GOODSMVT_CREATE from this delivery, fine, but, when come to BATCH.........ONLY the last batch of delivery item 10, is coming over/populating in MSEG-CHARG..........but, I need to bring all the batches of the item of the delievry into materail doc.........so,
(In this BAPI, I can see the goodsmvt_serialnumber for serial #s fine.)
1- for when coming to batch issue, Is I need to populate the goodsmvt_item table for EACH BATCH as a seperate item/record in this table , for the same 10 item of delivery?
I mean, Is I need to create a ITEM/record in Materail doc - MSEG tbl, for every BATCH of item 10 of delievry?
replies appreciated
thanq
Edited by: SAP ABAPer on Oct 29, 2008 6:06 PM

i clarified from my other func guy, answer is YES

Similar Messages

  • No material document created with BAPI_GOODSMVT_CREATE

    Hi all,
    I try to perform an IM transfer with 323 movement from BAPI_GOODSMVT_CREATE.
    It works with IM to IM storage location.
    It doesn't work when IM target storage location is connected to WM warehouse number and schould create an inbound delivery :
    the return code from the bapi is 0, there is no message in return table and no document number generated.
    (same data in MB1B works witout any problem)
    can you help me please ?

    thanks for your answers !
    I already try to find an OSS note (213 notes about this BAPI)...
    the call to the bapi is not performed directly, i use an intermediate storage in a table "ZGOODSMVT" which i use for other movements without any problem (same fields than BAPI parameters).
    (the 323 works when IM destination storage location is not connected to WM warehouse number).
    here is the code from first prog :
    form mvt_323.
    clear zgoodsmvt.
    zgoodsmvt-ref_doc_yr = mkpf-budat(4).
    zgoodsmvt-ref_doc = mkpf-mblnr.
    zgoodsmvt-ref_doc_it = mseg-zeile.
    zgoodsmvt-nseq = 0.
    zgoodsmvt-pstng_date = mkpf-budat.
    zgoodsmvt-doc_date = mkpf-budat.
    zgoodsmvt-ref_doc_no = mkpf-mblnr.
    zgoodsmvt-header_txt = 'Transfert automatique'.
    zgoodsmvt-gm_code = '04'. " Transfert
    zgoodsmvt-material = mseg-matnr.
    zgoodsmvt-plant = mseg-werks.
    zgoodsmvt-stge_loc = mseg-lgort.
    zgoodsmvt-batch = mseg-charg.
    zgoodsmvt-move_type = '323'.
    zgoodsmvt-entry_qnt = mseg-erfmg.
    zgoodsmvt-entry_uom = mseg-erfme.
    zgoodsmvt-item_text = 'Transfert automatique'.
    zgoodsmvt-move_plant = mseg-werks.
    zgoodsmvt-move_stloc = 'BVSG'.
    zgoodsmvt-batch = mseg-charg.
    zgoodsmvt-udate = sy-datum.
    zgoodsmvt-uname = sy-uname.
    zgoodsmvt-utime = sy-uzeit.
    INSERT zgoodsmvt.
    IF sy-subrc ne 0.
    retco = sy-subrc.
    EXIT.
    ENDIF.
    endform.
    here is the code from second prog :
      SELECT * FROM zgoodsmvt APPENDING CORRESPONDING FIELDS OF TABLE t
                              WHERE type NE 'S'.
      LOOP AT t.
        CLEAR  : ti, tr, ir.
        REFRESH: ti, tr.
        FREE   : ti, tr.
        MOVE-CORRESPONDING: t TO w_goodsmvt_header, t TO w_goodsmvt_code.
        MOVE-CORRESPONDING: t TO ti, t TO ir.
        APPEND ti. " item
        CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
          EXPORTING
            goodsmvt_header             = w_goodsmvt_header
            goodsmvt_code               = w_goodsmvt_code
            testrun                     = ptestrun
        IMPORTING
            GOODSMVT_HEADRET            =
            materialdocument            = w_materialdocument
            matdocumentyear             = w_matdocumentyear
          TABLES
            goodsmvt_item               = ti
            GOODSMVT_SERIALNUMBER       =
            return                      = tr.
        IF sy-subrc NE 0. " tjr à 0, les erreurs sont ds TR
          WRITE:/ text-250, sy-subrc.
        ENDIF.
    Thank you for your help,
    regards
    Eric

  • How to find Material Doc number.

    Hi experts,
    Is there a way we can identify the Material Doc number<MBLNR> from PP tables?
    Given only the following table-fields:
    afpo-kdauf
    afpo-kdpos
    afpo-aufnr
    afpo-charg
    I will be needing the Matdoc num so i can extract data from MSEG.
    Thanks,
    FAA

    hi..
    u have these fields in MSEG.
    afpo-aufnr = mseg-aufnr
    afpo-posnr = mseg-aufps
    apart from above, the following is also there..
    PS_PSP_PNR - WBS element
    NPLNR - Network Number - same as aufnr
    AUFPL - Routing number of operations in the order
    regards,
    Padma
    Edited by: Padmashree RamMaghenthar on Oct 15, 2008 1:57 PM

  • Material doc in AFRU table

    Hi Guys,
    Need a little help, Can any body tell me why sometimes there are enteries in AFRU table with material doc number (WABLNR) and some time material doc number field came as blank. Even though in MSEG i see material doc number (MBLNR) but its blank in AFRU-WABLNR?? Any help be appreciated.

    >
    samiaalis wrote:
    > Hi Guys,
    >
    > Need a little help, Can any body tell me why sometimes there are enteries in AFRU table with material doc number (WABLNR) and some time material doc number field came as blank. Even though in MSEG i see material doc number (MBLNR) but its blank in AFRU-WABLNR?? Any help be appreciated.
    AFRU table is for order confirmation
    Material document will create if the material is subjected to goods movement
    In case if you use auto GI and GR, then at the time of confirmation, system will post the goods movement
    at the time of operation confirmation, if the operation is linked to goods movement( if raw material is assigned to operation or final operation related to GR, that means auto GI or GR, then along with confirmation, material document will create.
    In case for particular operation , consider you have n't assign any raw material for the operation , at that time, for that confirmation, No material document is posted, for that confirmation, material document field in AFRU, will be blank

  • Transfer posting with reference to Material Doc and PO

    Dear all,
    Any Idea on how to use this function Transfer Posting wrt Material Doc/PO.
    Basically there is a genuine requirement from client which seems quite logical. There are two PO to different Vendors. Goods are receipt and sent to Quality Inspection. Once visual inspection is done, material from one Vendor is sent to Unrestricted and other still lying to be inspected. Material is transferred to Unrestricted. How does we tag that Stock of Vendor 1 is sent to unrestricted and Stock from vendor 2 is still on Inspection.
    There may be multiple Vendor in this case.
    Secondly, there are more than 50 line items in the PO, I have checked all the items and decide to sent it to unrestricted. And, to save time and confusion, I need to refer the GR/PO.
    No batch
    Any input. And how does this new function (attached image) is helpful. It is not possible to refer the PO/Mat doc during TP though the option is there.
    Regards,
    Lakhya

    Hello ,
    Case 1- Remining quantity will not be taken and sent back to vendor.
    you can just reject the quantity if you don`t want it any more.So only one invoice will be happened for the quantity which you have transfer
    if you will be returning the remaining quantity then do the config for auto return in  SPRO.
    So steps will be like this,
    1) create po for 100
    2) do GR in Quality
    3) post 90 in unrestricted and 10 in return while doing the UD in QA11
    4) do the invoice it will be done for 90.
    case 2 - remaining quantity will be taken in afterwards
    if you want partial UD then it wont be possible , And you have to either plan your receipts to accommodate full quantity of item in single lot .
    you can either do a enhancement to restrict the MIRO before UD is done using LMR1M001
    hope this help.Search on net you will get thread for this requirement.
    Thanks
    Kunal

  • PRINTING DELIVERY CHALLEN - MATERIAL DOC OF 541

    We have a requirement of printing Delivery challen which is Material document of 541 movement type.
    Now I have to link the Material document line item to P.O line item. for this I was referring MSEG table where I have P.O No but not the line item no. Without which I am not able to link P.O with material document.
    I am taking this linking  to display the receiving material (Subcontracted material) on Delivery challen.
    Can anybody tell me how to link this.
    Thanks
    Dhananjay

    For subcontracted material we issue input material to vendor through MB1B (Mov type-541)
    My client want take printout of this material document which should have the material issued to vendor and the receiving material against this issued material (Which is subcontracting material / Converted material).
    Now To fetch the subcontracting material / Converted material code having material document with me I use MSEG where I will get P.O no but line item no is not available which is required to link material doc with P.O.
    Is there any other way fetch the subcontracted material code based on MB1B material doc.
    Hope it is more clear.
    Thanks
    Dhanu

  • Reg. Getting Equipment No.(EQUNR) using Material Doc.(MBLNR)

    Hi all,
    In my ABAP program program, I need to fetch the Equipment No.(EQUNR) using Material Doc(MBLNR).
    I have only the Material Document as the input & I need to find the Equipment Numbers using that for further processings.
    Please guide me in this regard.
    Regards,
    Anbarasan K

    Hi
    Pass the Material document into MSEG table and fetch the EQUNR Field
    Better pass the document year also as the input along with the Document number
    Regards
    Amuthan M

  • Invoice Verification with material document - can we check material doc?

    hi,
    we have Invoice Verification with material documents in MIRO
    is there any way to find out (from MSEG or ekbe maybe) if a particular
    material document was invoiced or not ?
    (without comparing material doc and invoice lines ?)
    thank you,
    Regards,
    michal

    Hi
    Materials Management under Logistics Invoice Verification u2192 Incoming Invoice u2192 Activate Direct Posting to G/L Accounts and Material Accounts
    When you create an invoice containing only items without reference to a PO, the system cannot copy any information (such as currency or invoicing party) from the purchase order. This means that in addition to the document date and the amount, you first have to enter the following information in the header data:
    1. On the Basic data tab page: Currency
    2. On the Payment tab page: Baseline payment date
    3. On the Detail tab page: Invoicing party
    Finally, you enter the item data on the G/L Account and Material tab pages.
    use transaction FB60 to post vendor invoice
    SAM

  • Cancel Material Doc. problem

    Dear friends ,
    I have a Material doc must  be canceled used MBST to cancel Mtv 101 GR, and that mateirla has Enoutgh Qty in Project stock.
    But system reprot error :"Deficit of Delivered Quantity of item ......" if we operation on it by T-code :MBST.
    I have checked Doc date and Post date has in one finance Periered. 
    Could any one help me ?

    Hi,Csaba
    Thanks for your help first !
    THis Material GR with WBS is correct as same as it in Stock Qty.   and those error message when i MBST :
    "Deficit of Delivered quantity 1 EA : 11000057466 9119 0003 Q
        Message no. M7328
    Diagnosis
        This message can occur in the following situations:
        o   At goods receipt:
            The quantity planned for the inbound delivery falls short
        o   Upon a reversal or return delivery:
            This posting will return 1 EA more than the quantity poste
            receipt with reference to the inbound delivery.
    System Response
    If the message is an error message (E), the above is not allowed.
    If the message is a warning message (W), the system will allow yo
    input, but the warning is intended to prevent you entering a wron
    quantity.
    cedure
    In the case of a warning message, check the quantity entered.
    Note:
         The abbreviations in the short text of this message can have the
         following values:
         BA  = batch
         OR  = order
         PL  = plant
         PR  = previous period
    PU  = purchasing document
    RE  = reservation
    SL  = storage location
    VC  = consignment stock from vendor in storage location
    Br .
    WangYong

  • IP address of material doc

    Dear MM guys,
    Any method to find out which IP address a material doc been processed?
    Even via any audit transaction.
    Our scenario is 3 persons share a sap user account but not per work shift, we would like to find out who executed a corresponding GR material doc.
    Thanks in advance.

    Hi,
    This issue can be solved like this . While posting the MIGO in any of the reference fields of header or texts fields let them maintain their name or any other code so that this can be easily identified through  tables like mseg or any other . also sap stores the time of entry so that through that you can identify .
    Regards,

  • Unable to post the excise through J1IG w.r.t material doc....

    Hi
    Please need your inputs....
    We are configuring the trading import scenario.
    We created the material doc through MIGO and the user need not to capture in the exicse during the MIGO they need to capture the excise entries through J1IG.
    But I am unable to capture excise through J1IG with reference to material doc
    System will not capture all values.
    I can able to capture the excise during the MIGO but I am unable to capture the excise with material doc through J1IG
    Please give your valuable suggestion.
    Edited by: K. Raghuram on Dec 6, 2011 7:47 AM

    Thanks for your promt reply Nagarajan.
    We are using serial no functionality for that perticular material.
    While doing Goods issue wrt STO (351) we select serial nos for eg (10001 to 10105), qty-105.
    While doing GR wrt PO i.e. STO (in Rec Plant) those serial nos are not reflected.
    So we needed GR wrt Mat doc.
    Regards,
    Sachin Narvekar

  • Std Report to see Material doc. and FI doc.

    Hi all,
    I want a SAP standard report where i can see both the Material doc. as well as the FI doc. created against that in a single report.
    Please help.
    Thanks & Regards,
    Rajeev Kumar

    hi
    go to MB51 then excecute then u will see the report just go to
    system >list>save>local file  click and choose spreadsheet
    allthe report can be convert to excel format using this
    regards
    kunal
    award if helpful

  • Batch wise material value

    i wanted to see batch wise material's op stock, closing stock, receipt value, issue value (qty wise and value wise), then which report we can consider. i am looking mb5b but in this either batch is appearing or value is appearing, but batch, value both are not coming in one screen

    u can c only a limited information for the batch.
    if u want all these infrmation, then a report has to be developed thru ABAP development

  • I cannot do a GR for UNBW material, Free of Charge, for Intercompany PO.

    While trying to do a GR for a UNBW material Free of Charge from an inter-company STO, I am getting the following error msg:
    M7226 = " Update control of movement type incorrect (entry 101 _ X _B)”.
    I get the same message by doing the MIGO GR from PO or from MIGO GR from Outbound Delivery.
    I checked the table T156S and the required entry is missing:
    Movement Type = 101
    Update Value = blank
    Update Quantity = X
    Special Stock = blank
    Movement Indicator = B
    Receipt Indicator = blank
    Consumption = blank
    Scenario:
    Material Type UNBW is Quantity Control Only (No Cost).
    The PO Item has Account Assignment 8 (I/C Free of Charge)
    The vendor will not charge any cost (Totally Free of Charges)
    The field FREE is checked in the PO item
    Note:
    If in the GR/MIGO I enter a dummy value of $0.01 the document is posted. Of course the value posted is not correct because we do not have to pay anything to the vendor.
    I created a Customer Note to SAP, but they insist that the problem is in configuration.
    What could be the possible reason and what is the solution for this error?
    Thanks,

    Thanks for your reply. I checked that box and it becomes a free of charge item. Now when I do the MIRO that particular line item is missing. And when I do the F2 invoice for the third party order too that line is missing. My requirement is that I should be able to see in the F2 invoice as a free item. This is required for customs purposes.
    I have also tried checking the box : " Final Invoice " in the PO for that particular line item. ANd the FREE check box is still there , and the F2 invoice has the free line item but it is showing the std price. I would like to see the price as $0.00.
    Appreciate your help and time
    Thanks

  • GR for a UNBW material Free of Charge

    While trying to do a GR for a UNBW material Free of Charge from an inter-company STO, I am getting the following error msg:
    M7226 = " Update control of movement type incorrect (entry 101 _ X _B)”.
    I get the same message by doing the MIGO GR from PO or from MIGO GR from Outbound Delivery.
    I checked the table T156S and the required entry is missing:
    Movement Type = 101
    Update Value = blank
    Update Quantity = X
    Special Stock = blank
    Movement Indicator = B
    Receipt Indicator = blank
    Consumption = blank
    Scenario:
    Material Type UNBW is Quantity Control Only (No Cost).
    The PO Item has Account Assignment 8 (I/C Free of Charge)
    The vendor will not charge any cost (Totally Free of Charges)
    The field FREE is checked in the PO item
    Note:
    If in the GR/MIGO I enter a dummy value of $0.01 the document is posted. Of course the value posted is not correct because we do not have to pay anything to the vendor.
    I created a Customer Note to SAP, but they insist that the problem is in configuration.
    What could be the possible reason and what is the solution for this error?
    Thanks,
    Rafael

    There is no std way to achieve what u required
    You will have to use badi
    MB_MIGO_BADI
    and in that u will have to use interface
    LINE_MODIFY     Add / Change a Line (GOITEM)
    and
    CHECK_ITEM     Check Item Data of Goods Movement
    you will have to create a table where in u will have to assign gas material code to gas cylinder material code and the conversation factor
    conversation factor will be require if u want the system to calculate the number of cylinder on qty of gas
    if not u can enter the qty in MIGO only
    thus in badi u can write a logic where in if the material is in that Ztable and movement type 101 run the badi to add the line with material code in ztabe for gas cylinder for gas material code. and pass required entry to add the line
    hope if u give this logic to abaper he will write a code for u
    and ur issue will be solved
    Hope this will solve u issue

Maybe you are looking for

  • How can I use airplay with Macbook Pro 9,2 Mid 2012/ Mac OSX Lion 10.7.5

    What do I need to do to play Airplay on Apple TV from my computer.  The option is not in my display setting, so, obviously, I do not have the capability.  Do i need to upgrade my software?

  • ISO problem for 808 pureview

    For the last 22 months, I have been using 808 pureview & the thing I love the most is it's 41 mega pixel camera. Everything was fine until my phone's WIfi module failed to work. I gave the phone for repair & now what I got back is a sodding piece of

  • All iPOD music gone

    Ok, now I am furious... after doing the updater and such, iTunes for some reason updated all my songs from Library to my iPOD, I saw it... took some time... now looking at my iPOD, there is nothing there! Gone! Dont know why it wiped out my music but

  • Standby database unable to fetch missing archive sequence from primary

    Hi, My primary oracle db version is 10.2.0.5 which is n Windows 2003 server 32 bit in file system My standby database version is 10.2.0.5 which in wondows 2008 server in ASM instance. some of the archivelogs are not fetching by standby database from

  • No Sound in Leopard on G4

    I remember using iTunes and iChat audio chat yesterday. Today I booted up my computer and I couldn't get any sound. In the System Preferences it says there are no input or output devices found. How do I fix this?