Skip to Content

EWM Cancel picking


I want to do the cancel picking and create WT for each and every product that is picked. Following is the situation :

1) All the products are kept in HU.

2) So the picking is done from HU and putback (cancel picking) should also be through HU

3 )There are comlete HU picking and partial HU picking

4) In case of partial Hu picking, anotehr HU is created which takes multiple products.

5) We also want to have one click transaction so while unpacking the Hu with multiple prodcuts all teh prodcuts should be packed in different Hus as we have packing specifications created for each product.

6) Completely picked HU should be directed to a bin automatically.

One delivery has 300-400 line items. So we need this automation so in case of cancel picking we should not work on it manually.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Dec 06, 2018 at 05:32 AM

    Hi Pankaj,

    Looking at your requirement, it looks you need a custom solution to have automation in place.

    standard method would be to use /SCWM/CANCPICK and then use the 'Release + HUWT foreground' button to direct the single pallet to a full pallet location and the mixed pallet to repack work center. You can then unpack the mixed pallet and create a new pallet for each material and then do the putaway.

    For your automated solution, there are standard FM's available to suggest the putaway bin based on the PACI.



    Add comment
    10|10000 characters needed characters exceeded

  • Feb 07 at 09:25 PM


    I created a test program that will release stock for ODO after Picking Completed flag is set.

    *& Report ZRELEASE_STOCK
    report zrelease_stock.
    * Local Data
    data: lt_key_dlv type standard table of /scwm/s_aspk_dlv_cancpick,
          ls_key_dlv type /scwm/s_aspk_dlv_cancpick.
    data: gx_cancpick    type ref to /scwm/cl_cancpick_sp,
          gv_rejected    type boole_d,
          gs_inparam     type /scwm/s_sp_q_cancpick,
          gs_val_def     type /scmb/s_default_values_det,
          gt_val_defs    type /scmb/t_default_values_det,
          gx_attr_hndler type ref to /scmb/cl_attribute_handler,
          gx_msg_hndler  type ref to /scmb/cl_message_handler.
    parameters: p_docno  type /scdl/db_proci_o-docno obligatory.
    data: wa_docid type /scdl/db_proch_o-docid,
          wa_lgnum type /scwm/lgnum.
    data pt_data type /scdl/db_proci_o occurs 0.
    data: ls_data type /scdl/db_proci_o.
      clear:  gs_val_def.
      gs_val_def-v_fieldname    = 'LGNUM'.
      gs_val_def-v_mandatory    = abap_true.
      gs_val_def-v_memoryid     = '/SCWM/LGN'.
      gs_val_def-v_checkbox     = abap_false.
      gs_val_def-v_no_dropdown  = abap_true.
      append gs_val_def to gt_val_defs.
      /scmb/cl_ees_defaults=>init( iv_identifier        = '/SCWM/CANCPICK'
                                   iv_values_structure  = '/SCWM/S_SP_DEFAULT_CANCPICK'
                                   iv_extended          = abap_true
                                   it_values_definition = gt_val_defs                   ).
      create object gx_attr_hndler.
      create object gx_msg_hndler.
      create object gx_cancpick
          io_attribute_handler = gx_attr_hndler
          io_message_handler   = gx_msg_hndler.
      clear:  gs_inparam.
      gs_inparam-docno_h = p_docno.
      clear ls_key_dlv.
    * Get ODO Item Data
      refresh pt_data.
      select * into table pt_data
        from /scdl/db_proci_o
        where docno = p_docno.
      if not pt_data[] is initial.
        loop at pt_data into ls_data
          where itemtype = 'OBSP'.
          move-corresponding ls_data to ls_key_dlv.
          append ls_key_dlv to lt_key_dlv.
        gx_cancpick->/scmb/if_sp_transaction~cleanup( /scmb/if_sp_transaction=>sc_cleanup_end ).
        gx_cancpick->/scmb/if_sp_query~execute( exporting inparam = gs_inparam
                                                          query   = /scwm/if_sp_cancpick_c=>sc_qry_cancpick_item ).
        gx_cancpick->/scmb/if_sp_action~execute( exporting  aspect = /scwm/if_sp_cancpick_c=>sc_asp_item
                                                            inkeys = lt_key_dlv
                                                            action = /scwm/if_sp_cancpick_c=>sc_act_unassign_stock ).
        gx_cancpick->/scmb/if_sp_transaction~save( exporting  synchronously = abap_false
                                                   importing  rejected      = gv_rejected ).
        case gv_rejected.
          when abap_false.
            commit work and wait.
            gx_cancpick->/scmb/if_sp_transaction~cleanup( /scmb/if_sp_transaction=>sc_cleanup_commit ).
          when abap_true.
            rollback work.
            gx_cancpick->/scmb/if_sp_transaction~cleanup( /scmb/if_sp_transaction=>sc_cleanup_commit ).
          when others.
    Add comment
    10|10000 characters needed characters exceeded