Problem with updating serial numbers in sales order!

Hi,
I am trying to update serial numbers for a sales order in SAP. I tried using both SERNR_ADD_TO_AU and SERNR_ADD_TO_DOCUMENT. However, in both cases the FM returned the number of serial numbers created but these did not reflect in the sales order. The code for both is as below:
WA_SERXX-SDAUFNR = '0000001733'.
WA_SERXX-POSNR = '000010'.
WA_SERXX-KUNDE = '0000009000'.
WA_SERXX-VBTYP = 'C'.
WA_SERXX-SD_AUART = 'OR'.
WA_SERXX-SD_POSTYP = 'TAN'.
WA_SERNR-SERNR = '000000001234ABCDAR'.
APPEND WA_SERNR TO IT_SERNR.
WA_SERNR-SERNR = '000000001234ABCDAQ'.
APPEND WA_SERNR TO IT_SERNR.
CALL FUNCTION 'SERNR_ADD_TO_DOCUMENT'
  EXPORTING
    operation                       = 'SDAU'
    objkopf                         = 'SER02'
    serxx                           = wa_serxx
    material                        = 'P1-TEST'
   PROFILE                         = 'Z001'
    quantity                        = '2'
  M_CHARGE                        =
   J_VORGANG                       = 'PMS2'
  KMATNR                          =
  CUOBJ                           =
  R_MATERIAL                      =
  BSTCH                           =
  BSTUP                           =
  SNBWG                           =
  EMATN                           =
  KDAUF                           =
  KDPOS                           =
  AUTOMATIC                       = ' '
  NO_ENQUEUE                      = ' '
  MORE_ALLOWED                    = ' '
  BUDAT                           =
IMPORTING
   ANZSN                           = anzsn
   NEW_OBKNR                       = new_obknr
   SERIAL_COMMIT                   = serial_commit
   STATUS_NOT_ALLOWED              = status_not_allowed
  tables
    sernr                           = IT_SERNR
    r_sernr                         = it_ser1
  XVBPA                           =
CHANGING
  T_SMESG                         =
EXCEPTIONS
  KONFIGURATIONS_ERROR            = 1
  GENERAL_SERIAL_ERROR            = 2
  NO_PROFILE_OPERATION            = 3
  DIFFERENCE_IN_HEADER_DATA       = 4
  OTHERS                          = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
commit work and wait.
CALL FUNCTION 'SERNR_ADD_TO_AU'
  EXPORTING
    sernr                       = '000000001234ABCDAR'
    profile                     = 'Z001'
    material                    = 'P1-TEST'
  M_CHARGE                    =
    quantity                    = '1'
  J_VORGANG                   = 'PMS2'
  KMATNR                      =
  CUOBJ                       =
    document                    = '0000001733'
    item                        = '000010'
    debitor                     = '0000009000'
    vbtyp                       = 'C'
    sd_auart                    = 'OR'
    sd_postyp                   = 'TAN'
IMPORTING
   ANZSN                       = ANZSN
  ZEILEN_ID                   =
   SERIAL_COMMIT               = SERIAL_COMMIT
EXCEPTIONS
  KONFIGURATIONS_ERROR        = 1
  SERIALNUMBER_ERRORS         = 2
  SERIALNUMBER_WARNINGS       = 3
  NO_PROFILE_OPERATION        = 4
  OTHERS                      = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
COMMIT WORK AND WAIT.

hi,
In order to maintain customer specific serial numbers you can do the following steps:
1. Maintain the serial numbers provided by your client in tcode IQ01. this will create the customer serial numbers in the system.
2. In the material master under Sales View maintain the serial number profile as 0002. this is sap standard.
3. Once the above has been maintained you can assign serial numbers at the time of delivery and NOT in sales order.
I hope this helps.
Regards,
Vishesh

Similar Messages

  • Serial numbers on sales orders

    Hi
    can somebody tell me how do we maintain the serial number in Sales order in VA01/02...
    Inputs on SD serial numbers also welcome
    Thanks
    Muthu

    hi,
    You can get the information you need in the below link
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/LOMDSN/LOMDSN.pdf
    page no 17
    thanks
    krishna prasad

  • How to add serial number contolled item with serial numbers in sales order.

    Hi OM Functional Experts,
    I need a help on sales order booking.
    We have serial controlled items in our inventory. At the time of booking a sales order, we need to call the items with the appropriate serial numbers [ for example, if i book an item for a qty of 10, then, the system should get the details ( serial number ) of the 10 item's serial number ].
    And the serial numbers are Pre-defined by the organization for their internal tracking from the porcess 1 till end of the assembly line.
    The purpose of this step, is to reduce the particular serial numbered item from the inventory, when we reserve/pick release the sales order.
    thanks in advance.
    Rdx,
    J kannan
    Edited by: J Kannan on Feb 17, 2009 1:23 AM

    Kannan
    OK. Unfortunately reservations cannot be created at the serial number level. So the unsupported way of doing this is updating the mtl_serial_numbers tables. I hope you would know (by some means) which serial numbers you want to allocate to a specific sales orders. If you know, update group_mark_id column in mtl_serial_numbers table with your order_line_Id, This will avoid any one from picking the serial numbers (they will not come up in the LOV or will not be auto allocated).
    But you have to make sure to take it off when you actually want to pick this order line and allocate this serial number. So just before you pick release/ confirm this order line you need to update column back to null so that you can allocate that serial number.
    Thanks
    Nagamohan

  • Serial Numbers for Sales Orders

    We have a business Process where we do not maintain any serial numbers for the products. How ever one of our customer maintains serial numbers for the products that come to their warehouse.
    This customer will send in the serial numbers for each material and quantity in the inbound 850 Idoc and he wants those serial numbers to be printed on top of the boxes. so that he can scan them while receiving the GR and do automatic posting at thier system.
    we have to store this serial numbers against this sales order and print them in the shipping tags for the finished products  that are to be sent to  this customer.
    Now
    1) we do not want to use serial number profiles because it effects every sales order / delivery created for that material. the serial numbers should be assigned only to the orders from this specific customer.  Is there any way to acheive this?
    2) in the sap idoc 850 ( message type ORDERS05) how do we store the serial numbers. what segment and fields are available for this purpose. 
    3) how to save this serial numbers in the sap system against the sales order created for this customer.
    Your answers will be highy appreciated.
    Thanks,

    Thanks for all those wonderful replies..
    I am looking more at  a standard solution. with minor changes..
    Storing the serial numers in text items is possible but not practical, the more the quantity the more difficult and time consuming is this process for ex if this customer orders 10,000 qty. then it would be tough.. and again to solve that problem we have to break   the qty into multiple line items and this is only a alternatve but not a good solution i guess.
    I thought  this scenario should be more in practice because, customers can request us to put their serial numbers on the packing boxes that we send them.
    So just wondering if any our colleagues have already worked in this scenario.. While doing a search I saw a couple of questions regarding the same situations back in 2005 and 2007  but the questions were marked as answered without mentioning the solution they approached to solve this problem.
    Can any of you suggest me whether is this scneario a standard one ?

  • Serial numbers in sales order/delivery

    Hi All
    I have a question question on Bar code number generation. Please note that this is NOT a question on bar code printing or issuing output to printer.
    One of our customers requires serial numbers for all the products that we supply to them and they give us a serial number range from time to time and every material that we supply to them must go with one new serial number from their range.
    It may not be able to possible achieve the above functionality by maintaining serial numbers in the Material Master as it is customer specific. I need to maintain this number range somewhere and when the sales order/delivery is entered for this particular customer, the system must check (or some function module) the next available number and assign a number to the material.
    I checked all the possible help sites, but they do not explain about getting it for  particular customer. Can you please suggest me any methods or procedures to do it
    Regards
    Monika
    Edited by: Monika2010 on Jul 20, 2010 3:14 PM

    hi,
    In order to maintain customer specific serial numbers you can do the following steps:
    1. Maintain the serial numbers provided by your client in tcode IQ01. this will create the customer serial numbers in the system.
    2. In the material master under Sales View maintain the serial number profile as 0002. this is sap standard.
    3. Once the above has been maintained you can assign serial numbers at the time of delivery and NOT in sales order.
    I hope this helps.
    Regards,
    Vishesh

  • Update Serial Numbers to Production Order

    Hi,
    Has anyone used any Function module for updating the Serial Numbers to the Production Order Header. I am using the FM - SERNR_ADD_TO_PP . The Serial Numbers needs to be assigned when doing Goods Issue in MIGO. At this point The FM is updating the Serial Numbers to Order but it is putting it in Status PMP1.
    Once the Status is PMP1 it prevents anymore Serial Number update to the same production order using the same Function module. This is preventing us from doing partial Goods Issue in MIGO.
    Is there any more Function Module that can be used to updating the Serial Nos in the Production Order.
    Regards,
    Arunava

    HI rasheed,
    Check this resolution on table control for BDC.
    https://wiki.sdn.sap.com/wiki/x/DQGqAw
    Note: Do not post the same question twice.
    Regards,
    Bhumika

  • Problem with BOM Quant while creating Sales order with reference using BAPI

    Dear All,
    I am facing problem with creating a slaes order with reference to other sales order by using BAPI_SALESORDER_CREATEFROMDAT2 .
    Sales order is getting created but
    1. It exploding the BOM means the line items which are not there in the reference SO also coming in the new SO ( all BOM items are coming )
    2. Schedule line for BOM header item is getting copied to all sub items of BOM.
    Can any one help me out to prevent the above deviations in creating Sales order with reference by using BAPI_SALESORDER_CREATEFROMDAT2.
    Note: while passing the parameters to BAPI_SALESORDER_CREATEFROMDAT2
    all the data related to items is exactly the same as in the original Sales Order.
    Thanks in advnace.
    Regards,
    John

    Hi All,
    Can any one help me !!!!!!!!!!
    please

  • Serial Numbers during sales order creation

    hi gurus,
    i am creating a saels order from va01 and saving the serial numbers for the item from menu Extras technical objects and serial numbers , once saved where i can check the serial numbers for the items
    regards
    afzal

    Hi,
    You can find the SERIAL NUMBER for the Items in the DELIVERY->EXTRAS->SERIAL NUMBERS
    regards,
    santosh

  • Search Help Parameter Default - Problems with VKO and VTW in Sales Order

    Hello,
    we've implementend an own serchhelp for the material-search.
    The fields VKORG and VTWEG have the default VKO and VTW.
    If I open this searchhelp in VA03 those values are not filled, if I open it in MM03 or ME23N those values are filled.
    My user has the VKO and VTW-parameters set.
    We have no custom "preselect-code" implemented.
    If I change the values to VKU and VTW the output is the same (works in MM03 / ME23N but not in VA03) (copied default values from MAT1S search help, didn't change my user parameters!)
    What could be the problem?

    Our searchelp was in our own append ZA_SD_MAT1.
    Solution:
    We deleted this append and added our search-helps to SD_MAT1 and now everythings works in mm03, me23n and va03.

  • Serial number on sales order

    dear all!
    i am looking for the way to enter a serial number on sales order. i can enter it, but only via incompletion check. there is no menu entry, or button where to enter serial numbers in VA01, VA02.
    does anyone know how to enter the serial numbers for sales order items?
    thank you!
    matthias
    solved it by my own - link is technical objects ...
    Message was edited by:
            Matthias Rumplmaier

    Hi
        Serial number has to enter in the material master record, and setting have to be done in IMG-SD-BASIC FUNCTIONS-SERIAL NUMBERS-DETERMINE SERIAL NUMBER PROFILES.
    Similarly we can do the same even logistics execution.
    pls try these let me know it worked out or not.
    thank you
    with regards
    chaitanya

  • Problem with BAPI_OUTB_DELIVERY_CHANGE to update serial numbers

    hi All,
    I am using BAPI_OUTB_DELIVERY_CHANGE to update serial numbers. i am executing this directly in se37 giving delivery number alone in import parameters header_data, header_control and delivery.
    and giving delivery numer, item no and random serial no in tables ITEM_SERIAL_NO. when i execute  it is not throwing any errors. how ever the delivery is not updated with the serial no's.Return parameters is also nor showing any values.
    Any pointers to solve this would be appreciated.
    Regards,
    Sreekanth.

    Hi,
    You need to use BAPI_TRANSACTION_COMMIT just after BAPI_OUTB_DELIVERY_CHANGE .
    Mark WAIT = 'X' in the IMPORT parameter of BAPI_TRANSACTION_COMMIT.
    For testing if it is working or not:
    Goto SE37 --> click on FUNCTION MODULE --> TEST -->TEST SEQUENCES
    First give BAPI_OUTB_DELIVERY_CHANGE and then BAPI_TRANSACTION_COMMIT.
    Click on EXECUTE. Execute BAPI_OUTB_DELIVERY_CHANGE then 'BACK' and then BAPI_TRANSACTION_COMMIT with proper data.
    Goto the transaction from where you can check entry has been created or not.
    Regards

  • How to update Serial Number from Work Order to Sales order in MTO flow

    Helo Experts,
    I have a requirement to update automatically the Serial number in Make to Order flow, from the Work order to the sales order and then to delivery.
    In fact the flow is the following, when raising the sales order we don't know the SN, it will create a Work order with stock type E, when work order is released a Serial Number is assigned to the material created. After Goods receipt of WO, We need to have the SN updated in the sales order and then in the delivery.
    I tried with the parameters of Serial number profile, i was not able to update from WO to Sales Order.
    DO you have any idea how this requirement could be fullfiled? is it possible in standard?
    Thanks

    I don't think that it is possible in standard.

  • Update Serial Numbers and Qty with bapi_outb_delivery_change

    HI All
    I want to update serial numbers and quantity(delivery qty) for a delivery, this is mostly in case of short ship and over ship, I am using the BAPI for this updation, but I am getting errors to it.
    I am passing the following data in the BAPI:
    HEADER_DATA -
    > Delivery Number
    DELIVERY -
    > Delivery Number
    ITEM_DATA -
    > DELIV_NUMB(Delivery Number), DELIV_ITEM(Item), MATERIAL(material), DLV_QTY(Qty what i need to update in VL02n), FACT_UNIT_NOM(as 1), FACT_UNIT_DENOM (as 1), SALES_UNIT(VRKME), BASE_UOM(MEINS)
    ITEM_CONTROL -
    > DELIV_NUMB(delivery Number), DELIV_ITEM(Item), CHG_DELQTY(as 'X') .
    But I get this error message.
    "serial numbers are already maintained. Quantity cannot be changed"
    Please suggest how can I change both?
    Regards
    Swar

    Hi Swar
    I can maybe give you insight on why you are receiving the error message in hopes in can help you go to the right direction.  In the sales order for technical objects if you are maintaining lets say a qty of 2 each serial numbers.  When you create the delivery the system passes both serial numbers to the delivery. In cases of short ship (wanting to only ship one each) go to the serial number in the file menu under extras in the delviery and  before changing qty to one each; delete the serial number you are not shipping then change your qty this works.
    Edited by: Kim Blair on Sep 29, 2011 5:19 PM

  • HT201210 nowadays have many user have problem with update to ios7 and need active with apple id maybe in the future in order escape from these problems must be stop use these products else. Because of simple user don't know about this technology and somet

    nowadays have many user have problem with update to ios7 and need active with apple id maybe in the future in order escape from these problems must be stop use these products else. Because of simple user don't know about this technology and sometime just hear from other user that it 's difficult to use then force they change phone that use to handle to another.

    It is a feature to discourage the theft of iPhones by making them useless if resold. It's not going anywhere. It's simple: just don't buy a phone until you make sure that the activation lock has been disabled.

  • Serial number in sales order creation

    HI all,
         please help to me........
    My requirement a add the serial number BAPI sales order.
    problem is their no serial number in bapi structure.
                How to add serial number crate a salesorder bapi.
    serial number is RIPW0-SERNR.
    Thanks & Regards,
    SReddy.

    hi,
    refer to this link
    http://help.sap.com/saphelp_nw04/helpdata/EN/3e/0e1089c24611d1ad09080009b0fb56/content.htm
    refer to this code...
    Also if you set the * CONVERT_PARVW_AUART = 'X' parameter to 'X' you can use sold to party as SP and ship to party as SH.
    REPORT ZEX_BAPISALESORDCRT .
    --Data Declaration--
    Data: st_BAPISDHEAD like BAPISDHEAD, " Sales Order Header Data
    ta_BAPIITEMIN like BAPIITEMIN occurs 0 with header line, " Ln item
    ta_BAPIPARTNR like BAPIPARTNR occurs 0 with header line, " Partner
    d_BAPIRETURN1 like BAPIRETURN1, " Bapi return msg
    d_vbeln like bapivbeln-VBELN. " Sales Order Number
    Move the data to create sales order in the repective parameters------*
    move: 'TA' to st_BAPISDHEAD-DOC_TYPE, " Sales document type
    '15493' to st_BAPISDHEAD-PURCH_NO_C,
    '00010' to ta_BAPIITEMIN-ITM_NUMBER,
    'Y-351' to ta_BAPIITEMIN-MATERIAL,
    '1100' to ta_BAPIITEMIN-PLANT,
    '1' to ta_BAPIITEMIN-REQ_QTY,
    'AG' to ta_BAPIPARTNR-PARTN_ROLE, " Sold to Party
    '0000007777' to ta_BAPIPARTNR-PARTN_NUMB.
    Append the internal tables-------------------------------------------*
    append ta_BAPIPARTNR.
    clear ta_BAPIPARTNR.
    append ta_BAPIITEMIN.
    clear ta_BAPIITEMIN.
    Move ship to party---------------------------------------------------*
    move: 'RG' to ta_BAPIPARTNR-PARTN_ROLE, " Ship to party
    '0000007777' to ta_BAPIPARTNR-PARTN_NUMB.
    Append the internal tables-------------------------------------------*
    append ta_BAPIPARTNR.
    clear ta_BAPIPARTNR.
    Call the Bapi to create the sales order
    CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT1'
    EXPORTING
    ORDER_HEADER_IN = st_BAPISDHEAD
    WITHOUT_COMMIT = ' '
    CONVERT_PARVW_AUART = ' '
    IMPORTING
    SALESDOCUMENT = d_vbeln
    SOLD_TO_PARTY =
    SHIP_TO_PARTY =
    BILLING_PARTY =
    RETURN = d_BAPIRETURN1
    TABLES
    ORDER_ITEMS_IN = ta_BAPIITEMIN
    ORDER_PARTNERS = ta_BAPIPARTNR
    ORDER_ITEMS_OUT =
    ORDER_CFGS_REF =
    ORDER_CFGS_INST =
    ORDER_CFGS_PART_OF =
    ORDER_CFGS_VALUE =
    ORDER_CCARD =
    ORDER_CFGS_BLOB =
    ORDER_SCHEDULE_EX =
    if d_vbeln <> space.
    write: 'Sales order No. ', d_vbeln.
    endif.

Maybe you are looking for

  • Not very relevant, but how do I replace my old router with a new one?

    Recently I got a new router and I don't really know how to install it. When I first moved into my house, the guys from COX (my local internet service provider) had to come in, plug in the modem and router, go outside to the electrical box, flick some

  • Please Help! Unable to create a web service.

    Hi all, I have created a deployable proxy, a EJB with a stateless session bean, and a enterprise application project with the above ejb added. I add the deployable proxy into ejb, so that i can utilize the interface(web service) provided by the exter

  • My wife killed my iPhone 4 by washing it, how can I get a replacement handset?

    G'day all. My wife recently made my iPhone 4 lovely and shiny by washing it........ It's now dead and I've tried all the usual things to bring it back to life. I just would like a replacement. Is there any way I can get one through apple?

  • J2ME Game

    Hi all, i am making a J2ME game for my mobile(Nokia 7210). But i meet a problem that my mobile is just support MIDP1.0 that is no media api. I know sun provided Mobile Media API, can i use it? But the VM in the mobile do not have the classes, how can

  • Chat crashes with OS 10.5.8 on G4 Mac's

    I do not know if this is a known issue, but here is what I am struggling with. Hardware G4 Tower or Cube OS 10.5.8 with 1.5GB or RAM *Web Camera* External iSight camera (FW400) or Logitech QuickCam Vision Pro (USB) Issue iChat is launched. Then, when