Problem in cancelling a goods issue with WS_REVERSE_GOODS_ISSUE

Hi all,
I use the function module WS_REVERSE_GOODS_ISSUE in order to cancel a goods issue but most of the times it does not function as expected.
I call the function module as follows:
  CALL FUNCTION 'WS_REVERSE_GOODS_ISSUE'
    EXPORTING
      i_vbeln                   = w_delivery_doc
      i_budat                   = w_date
      i_tcode                   = 'VL09'
      i_vbtyp                   = 'J'
    TABLES
      t_mesg                    = it_mesg
    EXCEPTIONS
      error_reverse_goods_issue = 1
      error_message             = 2
      OTHERS                    = 3.
I traced the execution of the function module and found out that, although the field LIKP-VBELN contains the delivery document sent to the function module, when the statement PERFORM BELEG_LESEN(SAPMV50A) is executed the field LIKP-VBELN loses its contents (gets cleared).
Does anyone know why the function module does not work properly?
Am I missing something?
Thanks in advance,
GB

hi george,
why don't u use the function module 'BAPI_GOODSMVT_CREATE'
ds_code-gm_code = '06'.
CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
      EXPORTING
           goodsmvt_header  = ds_header
           goodsmvt_code    = ds_code
      IMPORTING
           materialdocument = dg_matdoc
           matdocumentyear  = dl_year
      TABLES
           goodsmvt_item    = dt_item
           return           = dt_return.
pls reward the points it it serves ur purpose
thanks
mahesh

Similar Messages

  • How to do good Issue with S/N from DI API

    Hai,
    I want to do good Issue with Serial Number using DI API but I got an error message <b>"\[IGE1.DocEntry]\[line:0],item serial is not found in Whse SR-5155 - 1 - R5155KGS ' (-5002)" </b>
    here is the code
    Set oGoodIssue = oCompanyDI.GetBusinessObject(oInventoryGenExit)
            oGoodIssue.DocDate = "12/14/2007"
                oGoodIssue.Lines.itemCode = "SR-5155"
                oGoodIssue.Lines.WarehouseCode = "R5155KGS"
                oGoodIssue.Lines.SerialNumbers.SystemSerialNumber = CStr(1)
                oGoodIssue.Lines.SerialNumbers.ManufacturerSerialNumber = "SR-0000001"
    oGoodIssue.Lines.SerialNumbers.InternalSerialNumber = "SR-0000001"
                oGoodIssue.Lines.SerialNumbers.SetCurrentLine 0
                oGoodIssue.Lines.SerialNumbers.Add
            retval = oGoodIssue.Add
            If retval <> 0 Then
                oCompanyDI.GetLastError errMsg, errMsg2
                sbo_application.messageBox errMsg & " (" & errMsg & ")"
            Else
                sbo_application.messageBox "Success"
            End If
    I check already from SAP BOne and the serial number is exist
    Can someone help me solve this problem
    Thanks and Regards,
    Arthur Siwan

    Hi Arthur,
    Try this code ( i had changed only one line of code in your original code)
    Set oGoodIssue = oCompanyDI.GetBusinessObject(oInventoryGenExit)
    oGoodIssue.DocDate = "12/14/2007"
    oGoodIssue.Lines.itemCode = "SR-5155"
    oGoodIssue.Lines.WarehouseCode = "R5155KGS"
    oGoodIssue.Lines.SerialNumbers.Add
    oGoodIssue.Lines.SerialNumbers.SystemSerialNumber = CStr(1)
    oGoodIssue.Lines.SerialNumbers.ManufacturerSerialNumber = "SR-0000001"
    oGoodIssue.Lines.SerialNumbers.InternalSerialNumber = "SR-0000001"
    oGoodIssue.Lines.SerialNumbers.SetCurrentLine 0
    retval = oGoodIssue.Add
    If retval 0 Then
    oCompanyDI.GetLastError errMsg, errMsg2
    sbo_application.messageBox errMsg & " (" & errMsg & ")"
    Else
    sbo_application.messageBox "Success"
    End If
    Hope it helps you
    Regards
    Vishnu

  • Cancel post goods issued....

    dear sap guruz....!!!
    i have a problem in production environment. during cancelling post goods issue.. When i reverse the post goods issue PGI the system gives an error
    "asking for account determination key PRD 0001 PRA 7920 is not maintained in MM customizing (valuation)....". This issue can be resolved if i give account determination for PRA 7920 BUT  what i am unable to understand is that why it is asking for account determination when there is no price difference in the post goods issue reversal which is issued on standard price for finished goods..  why we need PRA 7920 account determination..????
    please help me in this regard.... ..
    thanks
    sohail .

    Hi
    Check -
    What is the date of PGI document? and when you are doing PGI reversal. 
    whether costing has been done between these both dates in SAP.
    If the standard price durign PGI document and PGI reversal is different it will look for PRD
    And also check whether you are using two different currencies
    ~Thanks!
    Rajesh

  • Goods Issue with Serial number reversal

    Hi Experts,
    I have an item which is set to Inventory Item and Sales Item. I brought it in via Inventory/Good receipts to assign serial numbers.
    I realized I used the wrong Warehouse and wrong item Code ( I have 2 codes set the same but for different recording purposes)
    Unfortunately did I turn around and created a goods issue with the serial numbers to wash it but I do nee the serial numbers available to do my correct entry. How can I get my Serial numbers back which show no unavailable.
    If I try to set the item also as Purchase Item and try to do a return it wont show. Please advice.
    Thanks

    Hi,
    Receive again with correct item code and ware house with same serial number.
    If not, Please explain with an example.
    Thanks & Regards,
    Nagarajan

  • Goods Issue with reference to Purchase Order

    Hi MM Gurus,
    Is there any settings to do Goods Issue with reference to Purchase order?
    I want to capture the material price in purchase order during goods issue instead of standard price or moving average price.
    Thanks in advance
    Dinesh

    Hello Dinesh,
    Batch valuation is similar to split valuation. Here is the link on how batch valuation works.
    http://help.sap.com/saphelp_47x200/helpdata/en/25/283db54f7811d18a150000e816ae6e/content.htm
    Please check in sandbox environment before using.
    Hope this helps.
    Regards
    Arif Mansuri

  • Goods Issue with reference to Material document

    Hello,
    I would like to create Goods Issue with reference to material document (Transfer Posting document) , but the following message appears :
    "Selected material document does not correspond with action to be executed".
    Is it possible to create Goods Issue with reference to Transfer Posting (mov.type 311 - from stor.loc. to stor.loc.)  ?
    Thanks

    Thanks,
    probably I'll have to find another way to solve this business requirement of copying the transfer document data in GI.
    We have an auto created transfer postings via interface from another system and the main idea was to use already entered fields in transfer posting document such as material , quantity , text , goods recepient , etc. and not to enter them twice when GI should be created. In our case (it's a case for certain materials) it's always 1:1 relationship, so the idea was to facilitate the job of creating the GI, because GI should contain the same data as in transfer posting document.

  • Goods Issue with PI sheets

    Hi
    I am trying to do Goods Issue with PI sheet in SAP v4.7c. I have used the following characteristics however only the finish product and the qty comes up in the PI Sheet.
    can any one please let me know what should be done to have components assigned to the phase or irresepective of the phase:
    The scope of the Component Recipe destination is 03: for all order items and reservation and
    the position is 05: at the start of the phase
    The characteristics used are:
    PPPI_INPUT_GROUP          Material list
    PPPI_MESSAGE_CATEGORY          PI_CONS
    PPPI_PROCESS_ORDER          
    PPPI_RESERVATION          
    PPPI_RESERVATION_ITEM          
    PPPI_MATERIAL          
    PPPI_VARIABLE          'MYVAR&0050&'
    PPPI_MATERIAL_CONSUMED          
    PPPI_UNIT_OF_MEASURE          
    PPPI_AUTOMATIC_VALUE          Event date
    PPPI_AUTOMATIC_VALUE          Event time
    PPPI_OUTPUT_TEXT          Material
    PPPI_OUTPUT_CHARACTERISTIC          PPPI_MATERIAL
    PPPI_OUTPUT_TEXT          Material quantity-target value
    PPPI_OUTPUT_CHARACTERISTIC          PPPI_MATERIAL_CONSUMED
    PPPI_OUTPUT_TEXT          Unit of measure
    PPPI_OUTPUT_CHARACTERISTIC          PPPI_UNIT_OF_MEASURE
    PPPI_INPUT_REQUEST          Material quantity-actual value
    PPPI_DEFAULT_VARIABLE          'MYVAR&0050&'
    PPPI_REQUESTED_VALUE          PPPI_MATERIAL_CONSUMED
    PPPI_VALIDATION_FORMULA          ( X > ( 0.95 * 'MYVAR&0050&'))
    PPPI_VALIDATION_FORMULA          AND
    PPPI_VALIDATION_FORMULA          ( X < ( 1.05 * 'MYVAR&0050&'))
    PPPI_OUTPUT_TEXT          Unit of measure
    PPPI_OUTPUT_CHARACTERISTIC          PPPI_UNIT_OF_MEASURE
    PPPI_INPUT_REQUEST          Batch
    PPPI_REQUESTED_VALUE          PPPI_BATCH
    PPPI_MESSAGE_CATEGORY          SIGN
    PPPI_PROCESS_ORDER          
    PPPI_CONTROL_RECIPE          
    PPPI_OPERATION          
    PPPI_PHASE          
    Can any one please let me know where am I missing!!
    Thanks in advance
    -Rahul

    This is at control recipe creation or you are checking the instruction in the process order ?
    This is a simple PI which is working OK fo rmaterial consumption.
    Check it.
    10     PPPI_DATA_REQUEST_TYPE     Solicitud de datos simple
    20     PPPI_MESSAGE_CATEGORY     PI_CONS
    30     PPPI_UNIT_OF_MEASURE
    40     PPPI_OPERATION
    50     PPPI_OUTPUT_TEXT     Operación
    60     PPPI_OUTPUT_CHARACTERISTIC     PPPI_OPERATION
    70     PPPI_PHASE
    80     PPPI_OUTPUT_TEXT     Fase
    90     PPPI_OUTPUT_CHARACTERISTIC     PPPI_PHASE
    100     PPPI_RESERVATION
    110     PPPI_OUTPUT_TEXT     Reserva
    120     PPPI_OUTPUT_CHARACTERISTIC     PPPI_RESERVATION
    122     PPPI_RESERVATION_ITEM
    126     PPPI_OUTPUT_TEXT     Item
    127     PPPI_OUTPUT_CHARACTERISTIC     PPPI_RESERVATION_ITEM
    150     PPPI_PROCESS_ORDER
    160     PPPI_AUTOMATIC_VALUE     Hora de evento
    170     PPPI_AUTOMATIC_VALUE     Fecha de evento
    180     PPPI_MATERIAL
    190     PPPI_OUTPUT_TEXT     Code
    200     PPPI_OUTPUT_CHARACTERISTIC     PPPI_MATERIAL
    210     PPPI_MATERIAL_SHORT_TEXT
    220     PPPI_OUTPUT_TEXT     Material
    250     PPPI_OUTPUT_CHARACTERISTIC     PPPI_MATERIAL_SHORT_TEXT
    300     PPPI_MATERIAL_QUANTITY
    330     PPPI_OUTPUT_TEXT     Plan
    360     PPPI_OUTPUT_CHARACTERISTIC     PPPI_MATERIAL_QUANTITY
    400     PPPI_MATERIAL_CO_PRODUCT
    500     PPPI_OUTPUT_TEXT     Um
    600     PPPI_OUTPUT_CHARACTERISTIC     PPPI_UNIT_OF_MEASURE
    700     PPPI_INPUT_REQUEST     Lote
    800     PPPI_BATCH
    900     PPPI_REQUESTED_VALUE     PPPI_BATCH
    1000     PPPI_INPUT_REQUEST     Cantidad Real
    1100      PPPI_MATERIAL_CONSUMED
    1200     PPPI_REQUESTED_VALUE     PPPI_MATERIAL_CONSUMED
    1300     PPPI_INPUT_REQUEST     Sloc
    1400     PPPI_STORAGE_LOCATION
    1500     PPPI_REQUESTED_VALUE     PPPI_STORAGE_LOCATION

  • Error during Cancel of Goods Issue 202

    Dear All
                                                  i hv face an error during cancel of goods issue --> Areason has to be entered for mvmt type 202 " here in MIGO --> at detail data in where tab the field is missing simply say that user is not able to fine the block where to enter the reason then , pl help what to do  ?
    sap2008
    Edited by: sap2008 on Jan 8, 2009 6:37 AM

    Hi,
    If you have material document number created for movement type 210, you can simple use the transaction code MBST to cancel.
    If you don't have material document number and you are trying to post the material document for movement type 202.I will suggest you to use transaction code MIGO
    In MIGO select Goods Issue and in next field select Others and in Movement type select 202.
    Now you can cancel of goods issue.
    Regards,
    Manish

  • Cancel post goods issue..............

    How do I cancel post goods issue?Process of how it happens?pls tell me.

    by useing the tcode VL09
    You caGoods issue reversal means that you cancel the goods issue posting for a delivery. This function enables you to remove the posting without having to create a returns delivery and then having to post a goods receipt for it (see also Processing Returns After Goods Issue Posting). This function can be especially useful if you have accidentally posted goods issue, for example, and you would like to reverse it. Goods issue reversal usually occurs shortly after goods issue posting.
    Integration
    The cancellation document is integrated in the document flow of the delivery.
    Prerequisites
    Goods issue reversal is only possible for movement types for which a reversal movement type is defined in Customizing. Therefore, if you have defined your own movement types for goods issue, you must also define the respective reversal movement types and assign them to the movement types for goods issue.
    Range of Functions
    When you reverse goods issue for a delivery, the system creates a cancellation document that adopts the quantities and the valuation from the original goods issue document, and also executes the respective value and quantity posting to stock.Procedure
    From shipping, choose Post Goods Issue ® Cancellation/reversal.
    The Reverse goods movement screen appears.
    Enter your selection criteria, for example, route, goods issue date, shipping point, and so on, and choose Execute.
    A list of all deliveries that correspond to your selection criteria appears.
    From the list of deliveries to be reversed, you can branch directly to a list entry in the delivery by double clicking on the entry.
    Select the deliveries for which you wish to reverse goods issue and choose Cancel/reverse.
    A dialog box appears.
    In the dialog box, confirm that you want to reverse goods issue.
    Result
    The system reverses goods issue for all selected deliveries. It also generates a log of all the reversals executed and any errors that may have occurred.

  • I cannot cancel the goods issue because the delivery has been archived

    Dear Gurus,
    I have cancelled the MB1C goods receipt but I cannot cancel the goods issue because the delivery has been archived. Is it possible for you to fix this batch record any other way ?
    Early resposne would be appreciated !
    Thanks,
    Rafiq

    Dear Friends,
    Can u please help me out of this issue
    Thanks,
    Rafiq

  • Bapi for partial good issue with ref to reservation

    I have check the bapi for goods issue with ref to reservation. But how to take care scenario where good issue qty is less than reservation qty. How to map this in bapi.
    Please provide input its urgent
    Thanks
    JENA

    Hi Jena,
    Implement a check in your program calling  BAPI_GOODSMVT_CREATE.
    If you call BAPI_GOODSMVT_CREATE in your own program you have to fill the interface of it (GOODSMVT_HEADER, GOODSMVT_ITEM ...).
    So in the first step you have to select/colect all the required data for the interface. If you want to post a goods-issue with
    reference to a reservation you can implement a quantity-check in you own program similar to the checks in transaction MB1A or transaction MIGO which lead to message M7064. All the required informations are stored in the table "RESB - Items of reservation".
    This is the quantity-check implemented in transaction MIGO (... see note 409754):
    Take only reservation items with open quantity > 0 or
       or flag 'propose all items' is set (->default settings)
         l_open_quantity = ls_resitem-bdmng - ls_resitem-enmng.   >(1)
         CHECK l_open_quantity > 0 OR
                s_defaults-propose_all_items = abap_true.
    l_open_quantity  = open quantity -> is calulated here
    ls_resitem-bdmng = Requirement Quantity ->
                        table RESB / field BDMNG
    ls_resitem-enmng = Quantity withdrawn ->
                        table RESB / field ENMNG
    Furthermore you could check, whether the quantity you want to post now is larger than the (remaining) open quantity. If this
    not the case you could add this item to the interface-data. Otherwise you can ignore it and send a corresponding message or add the item to an error-log.
    After the check has been carried out and the interface has been filled with the valid items you can call BAPI_GOODSMVT_CREATE.
    In the customizing-transaction OMCQ you can maintain the category of messages. If you set the message M7 362 to the category "E - error message" the BAPI_GOODSMVT_CREATE will return with   this (error-)message as soon as the requirement quantity is exceeded by the goods-issue("Reserved quantity exceeded by ...").
    But: other processes/applications are using these settings too.
    This means: these processes/applications might have a different behaviour after your changes (error-message instead of a warning-  message ... for example).
    I hope this helps,
    Elaine.

  • My "undo" command does not work in the new version of GB.  Please advise.  This is a real problem.  I had no issues with  GB from iLife 11.

    My "undo" command does not work in the new version of GB.  Please advise.  This is a real problem.  I had no issues with  GB from iLife 11.

    Most likely you have Office 2004 which are PPC-only applications and will not work in Lion. Upgrade to Office 2011. Other alternatives are:
    Apple's iWork suite (Pages, Numbers, and Keynote.)
    Open Office (Office 2007-like suite compatible with OS X.)
    NeoOffice (similar to Open Office.)
    LibreOffice (a new direction for the Open Office suite.)

  • Cancell/reverse goods Issue WA 641 and outbound delivery

    Dear All,
    i have try to reverse goods issue with mbst, migo and also mb1a but it still can't reverse the material doc created.
    Regards,
    Jenny

    Hi
    Ask  your FI / MM consultant to do the setting for the same
    1.Go to OBYC -T code  and select the AUM transaction
    2.After selecting the transaction gives PoP up enter the Chart of accounts (check the chart of accounts in OB13 -tcode)
    3.then enter the details as below
        Valuation modification   Valuation class                            Debit               Creditg
         0001                              maintained in material master    G/L account   G/L account

  • Post Goods Issue with BAPI with reference to BOM

    Hi All,
    I want to post Goods Issue with BAPI / FM with reference to BOM.
    The requirement is like to replicate what we can do with MB1A with reference to BOM with BAPI / FM.
    Please give ur suggestions.
    Thanks in advance.
    Chintan.

    https://www.sdn.sap.com/irj/scn/advancedsearch?cat=sdn_forums_rm&query=kanban&adv=false&sortby=cm_rnd_rankvalue&sortmode=true&searchmode=similar&similardocsuri=/forumsrm/1_category/42_category/50_forum/34196_thread/322837_message

  • Pick and Pack / Goods Issue with Multi Batch Pickup

    Dear Friends,
    Can anyone explain me the process of Pick and Pack / Goods Issue with Multi Batch Pickup.
    Harsh

    Hi Mathur,
    Please refer these links on working with batch splits in deliveries :
    <a href="http://help.sap.com/saphelp_47x200/helpdata/en/38/c1853488601e33e10000009b38f83b/frameset.htm">Batch split</a>
    <a href="http://help.sap.com/saphelp_47x200/helpdata/en/38/c1853488601e33e10000009b38f83b/frameset.htm">Executing Multi batch</a>
    <a href="http://help.sap.com/saphelp_47x200/helpdata/en/38/c1853488601e33e10000009b38f83b/frameset.htm">Transferring Batch Data from Deliveries into Warehouse Management</a>
    Hope it helps. Please reward if useful.
    Thanks & Regards
    Sadhu Kishore

Maybe you are looking for

  • How to user PowerShell -replace to remove the dreaded em dash from a file name?

    I have a bunch of .msg files in a directory and want to zip them up (to send them to our spam filtering company), but I keep getting errors on file names that contain the em dash (-).  I believe it's (char)0x2014. [edited]... the correct syntax is [c

  • Post Goods Receipt before putaway

    Hi Experts, We're planning to implement SAP WM of SAP ECC 6.0. We're using inbound delivery for our goods receiving into the warehouse.  The process steps  that I found out from the SAP document is as follows: 1.  Create inbound delivery 2.  Pack if

  • Bug in ClassGeneratorWizard in ExtensionSDK on Jdev10.1.3.2

    I'm running the ExtensionsSDK version 10.1.3.40.66 on jdeveloper 10.1.3.2.0.4066, which is a little old but not much. I've been trying to learn how to write a Wizard extension and am studying this example. I deployed the extension, and it will load u

  • MBBE-"Quality. inspection" stock shows Inspection lot as "Unrestricted"

    Dear All, In MMBE, a material is available in "Quality Inspection" stock. We checked in "QA32". There we can see, it is in "Unrestricted use". How to move the stock from "Quality Inspection" to "Unrestricted use". Any suggestions. Regards, Mullairaja

  • Installation and run problem

    The previous user of my computer used jdk1.3. However, I got error message when I run the program(there is no compile error). The message is: Error occured during initialization of VM java/lang/NoClassDefFoundError: java/lang/Object Hence, I tried to