BAPI to update delivery note

hi all,
Is there any BAPI available with which we can update a delivery note and also if possible do PGI using it.
In case there are separate BAPI's for both the processes that will do for me.
Kindly help
Regards
Varun

Hi Varun,
You can use <b>WS_DELIVERY_UPDATE</b> or <b>WS_DELIVERY_UPDATE_2</b> ..
Following sample code works for Automatic PGI of an existing delivery. Use this as a basis and code for your requirement.
  DATA: ls_vbkok LIKE vbkok,
        lv_error_pgi TYPE xfeld,
        lt_prot LIKE prott OCCURS 0 WITH HEADER LINE,
        lwa_prot like prott.
  ls_vbkok-vbeln_vl = <your Delivery Note number>.
  ls_vbkok-wabuc = c_true.
  CALL FUNCTION 'WS_DELIVERY_UPDATE'
    EXPORTING
      vbkok_wa                           = ls_vbkok
      synchron                           = c_true
*         NO_MESSAGES_UPDATE                 = ' '
      commit                             = c_true
      delivery                           = <your Delivery Note number>
*         UPDATE_PICKING                     = ' '
*         NICHT_SPERREN                      = ' '
*         IF_CONFIRM_CENTRAL                 = ' '
*         IF_WMPP                            = ' '
*         IF_GET_DELIVERY_BUFFERED           = ' '
*         IF_NO_GENERIC_SYSTEM_SERVICE       = ' '
*         IF_DATABASE_UPDATE                 = '1'
*         IF_NO_INIT                         = ' '
*         IF_NO_READ                         = ' '
*         IF_ERROR_MESSAGES_SEND_0           = 'X'
*         IF_NO_BUFFER_REFRESH               = ' '
*         IF_NO_MES_UPD_PACK                 = ' '
*       IMPORTING
*         EF_ERROR_ANY_0                     =
*         EF_ERROR_IN_ITEM_DELETION_0        =
*         EF_ERROR_IN_POD_UPDATE_0           =
*         EF_ERROR_IN_INTERFACE_0            =
     ef_error_in_goods_issue_0          = lv_error_pgi
*         EF_ERROR_IN_FINAL_CHECK_0          =
   TABLES
*         VBPOK_TAB                          =
     prot                               = lt_prot[]
*         VERKO_TAB                          =
*         VERPO_TAB                          =
*         VBSUPCON_TAB                       =
*         IT_VERPO_SERNR                     =
*         IT_PACKING                         =
*         IT_PACKING_SERNR                   =
*         IT_REPACK                          =
*         IT_HANDLING_UNITS                  =
*         ET_CREATED_HUS                     =
  IF NOT lt_prot[] IS INITIAL.
    READ TABLE lt_prot WITH KEY msgty = 'E'.
    IF sy-subrc EQ 0.
****Errors Exist
***      Goods Issue Failed
    ENDIF.
  ELSE.
***    Goods Issue posted sucessfully
  ENDIF.
Hope this helps..
Sri
Message was edited by: Srikanth Pinnamaneni

Similar Messages

  • Bapi to update delivery date in confirmation tab in purchase order me22n tc

    Hi All,
    I am writing a BDC to update the data in confirmation tab for puchase orders for enjoy transaction.
    Please let me know how to updated delivery date in confirmation tab in purchase order(ME22N) using a bapi.
    I tried using BAPI_PO_CHANGE but found no parameter related to confirmations tab.  this BAPI has every thing to update like header data, item data, scheduling data..... except confirmation.
    So please let me know how to update the data in confirmation.
    We need to use only enjoy transaction ME22N not ME22 in BDC thats why we are looking for a BAPI.
    Regards,
    Venkat

    Hi
    Check the table parameter POCONFIRMATION in BAPI_PO_CHANGE
    U can see the field DELIV_DATE in the structure BAPIEKES.
    DELIVERY_DATE in the structure BAPIMEPOSCHEDULE as well.
    Regards,
    Dwaraka.S
    Edited by: Dwarakanath Sankarayogi on Feb 5, 2009 7:57 AM

  • Function Module or BAPI to update Delivery Date (LIKP-lfdat)

    Hello friends,
    I have a requirement to update Delivery Date (LIKP-lfdat) , is there any Function Module or BAPI to do that? any sample codes are appreciated.
    Thanks a lot!
    Edited by: Qiwei Yin on Dec 11, 2008 8:50 AM

    hi
    try this
    BAPI_SALESORDER_CHANGE
    hope this helps
    regards
    Aakash Banga

  • BAPI to update DELIVERY

    Hi Experts ,
    I want to update delivery in the FM IDOC_INPUT_SHPMNT .
    I have checked WS_DELIVERY_UPDATE_2 , but it is not released .
    Please help .

    Hi ,
    Both of them show in attributes as NOT RELEASED .
    Can we use them?
    REgards,
    Sunitha

  • How to update delivery note comment while creating return order

    Hi all.
      I need to update the delivery note comment in return sales order.Could you pls let me know is there any FM to achieve this pls?
    Thanks in advance.
    Thanks & Regards,
    sami.

    Hi,
    Try using SD_SALESDOCUMENT_CHANGE function module. Give the text in SALES_TEXT parameter.
    KR Jaideep,

  • Repeat transportorder confirmation - update delivery notes

    Hello everyone,
    Transport orders (WM) - based on delivery's - have been created and were confirmed. Unfortunately the corresponding update of delivery notes failed. (e.g. VBFA, LIPS not updeated).
    We are searching desperately for a solution to redo the confirmation (as everyone knows: delivery notes can not be invoiced until goods issue). We have batch management in place so it is possible that there are a couple batch splits. (means that manually adjusting tables is a no no - besides all other good reasons).
    If anybody out there has any idea (or programm) to do this, we would be very greatful.
    Regards
    Thomas
    EDIT: If this is the wrong thread, please let me know!
    Message was edited by:
            Thomas Hager

    Hello Thomas,
    Are you using one step or Two step confirmation?
    Please check out this OSS note.
    Note 574887 - Tables LIPS and VBUP/VBFA not in a consistent state
    Note 755506 - Incorrect updation of Picking & WM status for Std. Materials
    Note 664316 - Tips for the delayed delivery update for TO confirmation
    Hope this helps.
    Regards,
    Arif Mansuri
    Reward if answer is helpful.

  • Update qty in delivery note through bapi for migo

    hi im using bapi for migo upload
    my requiremnt is to update QTY IN DELIVERY NOTE in migo.
    i got the folowing error if i dont pass the quantity.
    qty and/0r delivery indicator or final issue indicator missing
    if i pass the quantity field then it is changing quantity in unity of entity and qty in SKU i dnt want to change this field
    here is my code,
    gmcode-gm_code = '01'.
        ls_GOODSMVT_HEADER-pstng_date = tdate . "sy-datum.
        ls_GOODSMVT_HEADER-doc_date   = sy-datum.
        ls_GOODSMVT_HEADER-pr_uname   = sy-uname.
    loop at itab.
      ls_GOODSMVT_HEADER-REF_DOC_NO = itab-LFSNR.
      it_goodsmvt-move_type  = itab-BWART.
      it_goodsmvt-po_number  = itab-EBELN.
      it_goodsmvt-PO_ITEM  = '10'.
      it_goodsmvt-STGE_LOC  = itab-LGORT.
    it_goodsmvt-QUANTITY  = itab-LSMNG.
    it_goodsmvt-BASE_UOM = 'KG'.
    it_goodsmvt-material = 'RC1092'.
    it_goodsmvt-entry_qnt = itab-LSMNG.
    it_goodsmvt-ENTRY_UOM  = 'KG'.
      it_goodsmvt-mvt_ind = 'B'.
      it_goodsmvt-plant = 'G001'.
    it_goodsmvt-NO_MORE_GR = 'X'.
    append it_goodsmvt.
    clear it_goodsmvt.
    CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
      EXPORTING
        goodsmvt_header               = ls_GOODSMVT_HEADER
        goodsmvt_code                 = gmcode-gm_code
      TESTRUN                       = ' '
      GOODSMVT_REF_EWM              =
    IMPORTING
      GOODSMVT_HEADRET              =
       MATERIALDOCUMENT              =  lf_MATERIALDOCUMENT
       MATDOCUMENTYEAR               = lf_MATERIALDOCYEAR
      tables
        goodsmvt_item                 = it_goodsmvt
      GOODSMVT_SERIALNUMBER         =
        return                        = return
      GOODSMVT_SERV_PART_DATA       =
      EXTENSIONIN                   =
    if return-type ca 'EA'.
          rollback work.
          message id '26' type 'I' number '000'
          with return-message.
        else.
          call function 'BAPI_TRANSACTION_COMMIT'
    EXPORTING
      WAIT          =
    IMPORTING
      RETURN        =
          wait up to 5 seconds.
        endif.
    select * fROM mseg
          INTO CORRESPONDING FIELDS OF TABLE IT_MSEG
                             where mblnr = lf_MATERIALDOCUMENT and
                                       MJAHR = lf_MATERIALDOCYEAR.
      LOOP AT IT_MSEG INTO WA_MSEG.
        IF WA_MSEG-LSMNG IS INITIAL.
          wa_mseg-lsmng = ITab-LSMNG.
          UPDATE MSEG from wa_mseg.
          commit work.
          wait up to 5 seconds.
        ENDIF.
      ENDLOOP.
    ENDLOOP.

    It is been done by implementing one implicit enhancement in FM: MAP2I_B2017_GM_ITEM_TO_IMSEG
    I have added the below functionality at the end of the function module.
    Just i have maped the ERFMG i.e ent_qnt(Received quanity) with LSMNG i.e qty.in del note
    All best for others.
    $$-Start: (1)----
    $$
    ENHANCEMENT 1  Z_EV_IMP_GOODSMOVEMENT.    "active version
    Populate the delivery note quantity and UoM
    IF IMSEG-ERFMG IS NOT INITIAL.
      MOVE IMSEG-ERFMG TO IMSEG-LSMNG.
      MOVE IMSEG-ERFME TO IMSEG-LSMEH.
    ENDIF.
    ENDENHANCEMENT.
    Thanks,
    Mahesh.Gattu
    Edited by: Maheshkumar gattu on Dec 3, 2010 4:35 PM

  • Need BAPI for uploading "Qty in Delivery Note" in MIGO

    Hi All,
    Please find the details of my requirement as below :
    Goto T-code MIGO and select goods receipt for a PO , here under material Item tab there is a field as "Qty in Delivery Note" under Quantity tab.
    I need to update this field using my BAPI. Is there is any FM , RFC for getting this output.
    Right now i am using BAPI  BAPI_GOODSMVT_CREATE, please let me know if any field of this BAPI can be used for thid purpose.
    Thanks,
    Mahesh.Gattu
    9900380302

    It is been done by implementing one implicit enhancement in FM: MAP2I_B2017_GM_ITEM_TO_IMSEG
    I have added the below functionality at the end of the function module.
    Just i have maped the ERFMG i.e ent_qnt(Received quanity) with LSMNG i.e qty.in del note
    All best for others.
    $$-Start: (1)----
    $$
    ENHANCEMENT 1  Z_EV_IMP_GOODSMOVEMENT.    "active version
    Populate the delivery note quantity and UoM
    IF IMSEG-ERFMG IS NOT INITIAL.
      MOVE IMSEG-ERFMG TO IMSEG-LSMNG.
      MOVE IMSEG-ERFME TO IMSEG-LSMEH.
    ENDIF.
    ENDENHANCEMENT.
    Thanks,
    Mahesh.Gattu
    Edited by: Maheshkumar gattu on Dec 3, 2010 4:35 PM

  • Bapi to Update Mnstransty  (Means of transportation) in  Inbound Delivery

    Hi Guys,
       Can you please let me know any BAPI which could update the mnstransty field (Means of Transportation ) in the Inbound Delivery. BAPI_INB_DELIVERY_CHANGE is not fulfilling this need.

    Hi ,
    u Can try this
    V50I Delivery BAPIs
    BAPI_INB_DELIVERY_CONFIRM_DEC BAPI for inbound delivery verification from a decentralized system
    BAPI_INB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Inbound Deliveries
    BAPI_OUTB_DELIVERY_CONFIRM_DEC BAPI for Outbound Delivery Verification from a Decentralized System
    BAPI_OUTB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Outbound Deliveries
    BAPI_OUTB_DELIVERY_SPLIT_DEC BAPI for Subsequent Outbound-Delivery Split from a Decentralized Syste
    V50R_CREA Create Delivery from Delivery Due List
    BAPI_DELIVERYPROCESSING_EXEC Delivery Processing: Deliver Preceding Document, Expand Delivery
    thanks
    anurag

  • Function Module or BAPI to update Sales Order (delivery Block)

    Hi,
    Is there a Function Module or BAPI available that can update the Delivery Block for a looping Sales Order?
    Thanks,
    John

    Hi,
    check this sample code to update delivery block..
    DATA: BAPISDH1X LIKE BAPISDH1X.
    DATA: BAPISDH1 LIKE BAPISDH1.
    PARAMETERS: P_VBELN LIKE VBAK-VBELN OBLIGATORY.
    PARAMETERS: P_LIFSK  LIKE VBAK-LIFSK OBLIGATORY.
    * Header
    BAPISDH1-DLV_BLOCK = p_lifsk.   " Delivery block
    * header X
    BAPISDH1X-DLV_BLOCK = 'X'.   " Delivery block
    BAPISDH1X-UPDATEFLAG = 'U'.
    CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
    EXPORTING
    salesdocument = P_VBELN
    order_header_in   = BAPISDH1
    order_header_inx = BAPISDH1X
    tables
    return = T_RETURN
    LOOP AT T_RETURN WHERE TYPE = 'E' OR TYPE = 'A'.
      EXIT.
    ENDLOOP.
    * Check for error messages.
    IF SY-SUBRC = 0.
      WRITE: / 'Sales order not updated', T_RETURN-MESSAGE.
    ELSE.
    * Successfully updated
      WRITE: / 'Sales order updated'.
    ENDIF.
    COMMIT WORK.
    Thanks
    Naren

  • How to update delivery block in delivery(vl02n) using BAPI

    hi all,
    i have to update delivery block of a delivery using a BAPI. can any one suggest which bapi i have to use. and if possible let me know what are the mandatory fields that i have to fill in that bapi.
    thank you all in advance

    HI,
    Use the BAPI BAPI_OUTB_DELIVERY_CHANGE..
    Pass the delivery number DELIV_NUMB in both HEADER_DATA and HEADER_CONTROL..
    In HEADER_DATA-DLV_BLOCK pass the delivery block.
    In HEADER_CONTROL-DLV_BLOCK_FLG pass 'X'
    Thanks
    Naren

  • BAPI for updating Maintain Duration in Transportation and Delivery scheduling

    Hi all,
    Iam looking for a BAPI to update the Duration Times in Transportation and Delivery scheduling. I reluctant to use recording on SM30 Table maintenance T code and use it in LSMW. Is there a BAPI or Standard i/p Program to load these details. I have more than 200000 records to input.
    A list of all BAPI's in Transportation Management module would be great as well.
    Regards,
    Avi

    Hi,
    @praveen: I tried the solution provided by you and it worked for me in this context. But it seems this BADI gets triggered every time the delivery is getting saved. So for my test purposes, I'm triggering this BADI in a program, but in actual scenario, the BADI would be called on every sy-ucomm = 'SICH_T' i.e. SAVE. hence, I can't separate my piece of code using this condition.
    I'm trying to call my FM(update module in collective run mode) inside this BADI in backgrnd task as a separate unit but this doesn't seem to work.
    Any more suggestions?
    Thanks
    Ashish

  • WSH_DELIVERY_DETAILS_PUB.Update_Shipping_Attributes not updating delivery..

    Hi guys,
         If I am not wrong is the API to update delivery details in WSH_DELIVERY_DETALS TABLE.
    Here i am updating tracking_number for a given delivery_detail_id, but its not working.
    Please help me if I am doing amy mistake.
    create OR REPLACE procedure UPDATE_DETAILS_PROC_SAT is
    l_changed_rec WSH_DELIVERY_DETAILS_PUB.ChangedAttributeTabType;
    l_init_rec WSH_DELIVERY_DETAILS_PUB.ChangedAttributeRecType;
    l_return_status VARCHAR2(1000);
    l_msg_count NUMBER;
    l_msg_data VARCHAR2(1000);
    error exception;
    begin
    WSH_DELIVERY_DETAILS_PUB.Init_Changed_Attribute_Rec(p_init_rec => l_init_rec,
    x_return_status => l_return_status);
    l_init_rec.delivery_detail_id :=111482;
    l_init_rec.tracking_number := 184854;
    l_init_rec.shipped_quantity := 1;
    l_changed_rec(1) :=l_init_rec;
    WSH_DELIVERY_DETAILS_PUB.Update_Shipping_Attributes(p_api_version_number => 1.0,
    p_init_msg_list => FND_API.G_TRUE,
    p_commit => FND_API.G_TRUE,
    x_return_status => l_return_status,
    x_msg_count => l_msg_count,
    x_msg_data => l_msg_data,
    p_changed_attributes => l_changed_rec,
    p_source_code => 'OE');
    end;

    What is the status of this delivery detail ID? Why are you passing the shipped quantity? Do you want to ship the delivery (hence associated details) and update the tracking number?
    Remove the shipped_quantity and try updating first and then use deliveries actions to ship the delivery.
    Thanks
    Nagamohan

  • Cannot update delivery attributes: the following field(s) are not updatable

    Hi. I create in EBS simple Order
    Now , my goal is to create a delivery , pick , change shipping quantity and ship confirm. Here is my code
    DECLARE
    p_sales_order NUMBER := 10014445;
    p_line_number NUMBER := 1.1;
    p_org_id NUMBER := 308;
    l_shipped_quantity NUMBER := 5;
    p_api_version_number NUMBER := 1.0;
    init_msg_list VARCHAR2(200);
    l_commit VARCHAR2(30);
    x_msg_details VARCHAR2(3000);
    x_msg_summary VARCHAR2(3000);
    x_return_status VARCHAR2(3);
    x_msg_count NUMBER;
    x_msg_data VARCHAR2(3000);
    p_validation_level NUMBER;
    v_errbuf VARCHAR2(2000);
    v_retcode VARCHAR2(20);
    v_released_status wsh_delivery_details.released_status%TYPE;
    v_inv_interfaced_flag wsh_delivery_details.inv_interfaced_flag%TYPE;
    v_oe_interfaced_flag wsh_delivery_details.oe_interfaced_flag%TYPE;
    v_source_code wsh_delivery_details.source_code%TYPE;
    v_pending_interface_flag wsh_trip_stops.pending_interface_flag%TYPE;
    l_changed_attributes wsh_delivery_details_pub.changedattributetabtype;
    l_source_code VARCHAR2(30) := 'OE';
    -- Parameters for WSH_DELIVERIES_PUB
    p_delivery_name VARCHAR2(30);
    p_action_code VARCHAR2(15);
    p_asg_trip_id NUMBER;
    p_asg_trip_name VARCHAR2(30);
    p_asg_pickup_stop_id NUMBER;
    p_asg_pickup_loc_id NUMBER;
    p_asg_pickup_loc_code VARCHAR2(30);
    p_asg_pickup_arr_date DATE;
    p_asg_pickup_dep_date DATE;
    p_asg_dropoff_stop_id NUMBER;
    p_asg_dropoff_loc_id NUMBER;
    p_asg_dropoff_loc_code VARCHAR2(30);
    p_asg_dropoff_arr_date DATE;
    p_asg_dropoff_dep_date DATE;
    p_sc_action_flag VARCHAR2(10);
    p_sc_intransit_flag VARCHAR2(10);
    p_sc_close_trip_flag VARCHAR2(10);
    p_sc_create_bol_flag VARCHAR2(10);
    p_sc_stage_del_flag VARCHAR2(10);
    p_sc_trip_ship_method VARCHAR2(30);
    p_sc_actual_dep_date VARCHAR2(30);
    p_sc_report_set_id NUMBER;
    p_sc_report_set_name VARCHAR2(60);
    p_sc_defer_interface_flag VARCHAR2(60);
    p_sc_send_945_flag VARCHAR2(60);
    p_sc_rule_id NUMBER;
    p_sc_rule_name VARCHAR2(60);
    p_wv_override_flag VARCHAR2(10);
    p_asg_pickup_stop_seq NUMBER;
    p_asg_dropoff_stop_seq NUMBER;
    x_trip_id VARCHAR2(30);
    x_trip_name VARCHAR2(30);
    fail_api EXCEPTION;
    x_debug_file VARCHAR2(100);
    l_ship_method_code VARCHAR2(100);
    l_user_id NUMBER;
    l_resp_id NUMBER;
    l_appl_id NUMBER;
    CURSOR c_ord_details IS
    SELECT DISTINCT det.source_header_number sales_order,
    det.org_id,
    det.source_line_number,
    det.source_header_id,
    det.source_line_id,
    det.source_header_type_name,
    det.inventory_item_id,
    det.requested_quantity,
    det.delivery_detail_id,
    (SELECT concatenated_segments
    FROM mtl_system_items_kfv
    WHERE inventory_item_id = det.inventory_item_id
    AND organization_id = det.organization_id) ordered_item,
    det.organization_id,
    det.src_requested_quantity,
    det.shipped_quantity,
    del.delivery_id,
    del.status_code delivery_status_code,
    det.released_status pick_release_status,
    det.oe_interfaced_flag,
    det.inv_interfaced_flag
    FROM wsh_delivery_details det,
    wsh_delivery_assignments asn,
    wsh_new_deliveries del
    WHERE 1 = 1
    AND det.delivery_detail_id = asn.delivery_detail_id
    AND asn.delivery_id = del.delivery_id(+)
    AND det.source_header_number = 1199656
    AND det.source_line_number = '1.1'
    AND det.org_id = 10102
    AND shipped_quantity IS NULL
    AND NVL(del.status_code, 'OP') <> 'CL'
    and det.delivery_detail_id =21439836
    /* AND det.released_status = 'Y'*/;
    BEGIN
    -- Initializing the Applications
    SELECT user_id INTO l_user_id FROM fnd_user WHERE user_name = 'MSHAPIRA';
    SELECT responsibility_id, application_id
    INTO l_resp_id, l_appl_id
    FROM fnd_responsibility_vl
    WHERE responsibility_name = 'OM Super User - UDS UK';
    fnd_global.apps_initialize(l_user_id, l_resp_id, l_appl_id);
    FOR i IN c_ord_details LOOP
    DBMS_OUTPUT.put_line('Initializing the Application for Shipping Transactions');
    -- Mandatory initialization for R12
    mo_global.set_policy_context('S', i.org_id);
    mo_global.init;
    -- Ship Confirming
    p_delivery_name := TO_CHAR(i.delivery_id);
    DBMS_OUTPUT.put_line('Before Shipping, Calling WSH_DELIVERY_DETAILS_PUB API to Update Shipping Attributes');
    DBMS_OUTPUT.put_line('=============================================');
    l_changed_attributes(1).delivery_detail_id := i.delivery_detail_id;
    l_changed_attributes(1).shipped_quantity := 5;
    wsh_delivery_details_pub.update_shipping_attributes(p_api_version_number => 1.0,
    p_init_msg_list => init_msg_list,
    p_commit => l_commit,
    x_return_status => x_return_status,
    x_msg_count => x_msg_count,
    x_msg_data => x_msg_data,
    p_changed_attributes => l_changed_attributes,
    p_source_code => l_source_code);
    IF (x_return_status <> wsh_util_core.g_ret_sts_success) THEN
    RAISE fail_api;
    DBMS_OUTPUT.put_line('Failed to Update the Shipping Attributes');
    ELSE
    DBMS_OUTPUT.put_line('Successfully Updated the Shipping Attributes');
    END IF;
    BEGIN
    SELECT shipping_method_code
    INTO l_ship_method_code
    FROM oe_order_headers_all
    WHERE order_number = i.sales_order
    AND org_id = i.org_id;
    EXCEPTION
    WHEN OTHERS THEN
    l_ship_method_code := NULL;
    END;
    p_action_code := 'CONFIRM'; -- The action code for ship confirm
    p_sc_action_flag := 'S'; -- Ship entered quantity.
    p_sc_intransit_flag := 'Y';
    --In transit flag is set to 'Y' closes the pickup stop and sets the delivery in transit.
    p_sc_close_trip_flag := 'Y'; -- Close the trip after ship confirm
    p_sc_trip_ship_method := l_ship_method_code; -- The ship method code
    p_sc_defer_interface_flag := 'Y';
    p_sc_stage_del_flag := 'Y';
    p_sc_create_bol_flag := 'N';
    p_wv_override_flag := 'N';
    -- API Call for Ship Confirmation
    DBMS_OUTPUT.put_line('Calling WSH_DELIVERIES_PUB to Perform Ship Confirmation');
    DBMS_OUTPUT.put_line('=============================================');
    wsh_deliveries_pub.delivery_action(p_api_version_number => 1.0,
    p_init_msg_list => init_msg_list,
    x_return_status => x_return_status,
    x_msg_count => x_msg_count,
    x_msg_data => x_msg_data,
    p_action_code => p_action_code,
    p_delivery_id => i.delivery_id,
    p_delivery_name => p_delivery_name,
    p_asg_trip_id => p_asg_trip_id,
    p_asg_trip_name => p_asg_trip_name,
    p_asg_pickup_stop_id => p_asg_pickup_stop_id,
    p_asg_pickup_loc_id => p_asg_pickup_loc_id,
    p_asg_pickup_stop_seq => p_asg_pickup_stop_seq,
    p_asg_pickup_loc_code => p_asg_pickup_loc_code,
    p_asg_pickup_arr_date => p_asg_pickup_arr_date,
    p_asg_pickup_dep_date => p_asg_pickup_dep_date,
    p_asg_dropoff_stop_id => p_asg_dropoff_stop_id,
    p_asg_dropoff_loc_id => p_asg_dropoff_loc_id,
    p_asg_dropoff_stop_seq => p_asg_dropoff_stop_seq,
    p_asg_dropoff_loc_code => p_asg_dropoff_loc_code,
    p_asg_dropoff_arr_date => p_asg_dropoff_arr_date,
    p_asg_dropoff_dep_date => p_asg_dropoff_dep_date,
    p_sc_action_flag => p_sc_action_flag,
    p_sc_intransit_flag => p_sc_intransit_flag,
    p_sc_close_trip_flag => p_sc_close_trip_flag,
    p_sc_create_bol_flag => p_sc_create_bol_flag,
    p_sc_stage_del_flag => p_sc_stage_del_flag,
    p_sc_trip_ship_method => p_sc_trip_ship_method,
    p_sc_actual_dep_date => p_sc_actual_dep_date,
    p_sc_report_set_id => p_sc_report_set_id,
    p_sc_report_set_name => p_sc_report_set_name,
    p_sc_defer_interface_flag => p_sc_defer_interface_flag,
    p_sc_send_945_flag => p_sc_send_945_flag,
    p_sc_rule_id => p_sc_rule_id,
    p_sc_rule_name => p_sc_rule_name,
    p_wv_override_flag => p_wv_override_flag,
    x_trip_id => x_trip_id,
    x_trip_name => x_trip_name);
    IF (x_return_status <> wsh_util_core.g_ret_sts_success) THEN
    DBMS_OUTPUT.put_line('Ship confirm has not been Completed For SO => ');
    ROLLBACK;
    RAISE fail_api;
    ELSE
    DBMS_OUTPUT.put_line('Ship confirm Successfully Completed For SO => ');
    COMMIT;
    DBMS_OUTPUT.put_line('Checking the Delivery Status after delivery action API Call');
    DBMS_OUTPUT.put_line('==========================================');
    SELECT wdd.source_code,
    wdd.released_status,
    wdd.inv_interfaced_flag,
    wdd.oe_interfaced_flag,
    wts.pending_interface_flag
    INTO v_source_code,
    v_released_status,
    v_inv_interfaced_flag,
    v_oe_interfaced_flag,
    v_pending_interface_flag
    FROM wsh_trips wtr,
    wsh_trip_stops wts,
    wsh_delivery_legs wlg,
    wsh_new_deliveries wnd,
    wsh_delivery_assignments wda,
    wsh_delivery_details wdd
    WHERE wtr.trip_id = wts.trip_id
    AND wts.stop_id = wlg.pick_up_stop_id
    AND wts.pending_interface_flag = 'Y'
    AND wdd.inv_interfaced_flag <> 'Y'
    AND wlg.delivery_id = wnd.delivery_id
    AND wnd.delivery_id = wda.delivery_id
    AND wda.delivery_detail_id = wdd.delivery_detail_id
    AND wnd.delivery_id = p_delivery_name
    AND wdd.source_line_id = i.source_line_id;
    IF (v_source_code = 'OE' AND v_released_status = 'C' AND
    v_inv_interfaced_flag <> 'Y' AND v_oe_interfaced_flag <> 'Y' AND
    v_pending_interface_flag = 'Y') THEN
    DBMS_OUTPUT.put_line('The Delivery has been Shipped & the Next Step is - Run Interface');
    DBMS_OUTPUT.put_line('===========================================');
    -- API Call for Submitting Interface Trip Stop
    wsh_ship_confirm_actions.interface_all_wrp(errbuf => v_errbuf,
    retcode => v_retcode,
    p_mode => 'ALL',
    p_stop_id => NULL,
    p_delivery_id => p_delivery_name,
    p_log_level => 0,
    p_batch_id => NULL,
    p_trip_type => NULL,
    p_organization_id => i.organization_id,
    p_num_requests => 1,
    p_stops_per_batch => 1);
    ELSE
    DBMS_OUTPUT.put_line('The Delivery has not Shipped Properly');
    END IF;
    END IF;
    END LOOP;
    EXCEPTION
    WHEN fail_api THEN
    DBMS_OUTPUT.put_line('==============');
    DBMS_OUTPUT.put_line('Error Details If Any');
    DBMS_OUTPUT.put_line('==============');
    wsh_util_core.get_messages(p_init_msg_list => 'Y',
    x_summary => x_msg_summary,
    x_details => x_msg_details,
    x_count => x_msg_count);
    IF x_msg_count > 1 THEN
    x_msg_data := x_msg_summary ||' '||x_msg_details;
    DBMS_OUTPUT.put_line(x_msg_data);
    ELSE
    x_msg_data := x_msg_summary||' '|| x_msg_details;
    DBMS_OUTPUT.put_line(x_msg_data);
    END IF;
    END;
    But at the stage of updating delivery attributes I get the following error message
    Warning: For Delivery Detail 21439836, the following field(s) are not updatable: SHIPPED_QUANTITY.
    Why?

    Hi Paul
    Looks like the authorisation is failing due to a bad registration for some reason.
    Would you be kind enough to clear out the registration to ensure we are dealing with a fresh start and no information is being used which may have become corrupt. You may do this by following this procedure;
    Remove existing reg details
    # usr/lib/cc-ccr/bin/eraseCCRRepository
    List /tmp/RegistrationProfile.properties file
    # cat /tmp/RegistrationProfile.properties
    Attempt re-registration
    # sconadm register -a -r /tmp/RegistrationProfile.properties
    Send us the full output of the commands above if you would please.

  • Delivery Note Quantity in BAPI

    Dear Gurus,
    I am working in SAP-AFS 6.2 and using BAPI ( /AFS/BAPI_GOODSMVT_CREATE )  for Z-Development of Goods Recepit of RM and FG.
    This BAPI I am using for Goods Receipt against Production Order, Purchase Order( Including Subcontracting Purchase Order).
    I am not able to find the feild for "Delivery Note Quantity" in that BAPI , Can any one help me out ?
    Regards
    Siddharth

    >
    Kishore Kumar Chiluka wrote:
    > Hi
    >
    > This field is not avialbal in the BAPI.
    > LSMNG - Quantity in Unit of Measure from Delivery Note
    >
    > Why do you require this data, i think SAP has not provided this field as you will be receiving this data
    > from interface and the delivery note qty is equal to Qty in unit of entry.
    >
    > Try finding out some enhancement point in this BAPI - hope it will be helpful but i am not sure how we can use that...
    >
    >
    > Thanks & Regards
    >
    > Kishore
    Is it really ok if the LSMNG field is left blank in the MIGO through BAPI_GOODSMVT_CREATE? I mean does it affect any other transaction?
    pk

Maybe you are looking for

  • Move iTunes files from v9 to v10 on another computer

    Hi, I have iTunes 9 and all my music on my laptop running Tiger. I have iTunes 10 and no music on my desktop running Snow Leopard. What's the best way to get my iTunes data from the laptop to the desktop and avoid any issues? The iMac system has been

  • Problems with Vista syncing photos

    One of the main reasons I got my 80GB Ipod was so that I could always have all my pics with me of family. It all worked until Vista...Optimizing Photos for Ipod before it syncs takes 10-20 seconds a photot. With XP, it takes less than a second a phot

  • Shutter sound that camera makes when taking a picture sound like it's dying.

    The shutter sound that my iphone 5s makes when I take a picture sounds like it's dying. Anyone else have this happen on their phone? This hasn't caused a problem with taking pictures but it sounds weird.

  • Help opening a .wps file on my macbook...

    i just recently got a macbook, and i love it, but am still new to it. i have some word documents on my external hard drive that are saved from my old windows based computer that i would like to open on my mac as the windows computer doesnt work any m

  • Setting back ground on images to be transparent

    Hello, Is there a way to set a picture box to be transparent when mounted in Indesign. We are mounting EPS's into indesign and they have a clipping path. The background to the image is always white can this be set in a Document preference to set back