Skip to Content
0

Call BDC(VL32N) to generate HU by delivery, then call FM WS_DELIVERY_UPDATE execute PGR failed

May 16 at 03:46 AM

37

avatar image
Former Member

Hi Experts,

This is my scenario that step call BDC to generate HU is successful. but call FM WS_DELIVERY_UPDATE to PGR failed. Error message is "No HUs have been transferred for material & & &". In the debug mode, I found the database VEKP&VEPO has exist HU data. But in the FM WS_DELIVERY_UPDATE, a sub-FM HU_GET_HUMSEG will check internal table GT_XVEKP & GT_XVEPO (empty internal table so that raise error message). Who knows about this scenario and solve solution? Thanks!

Regards,

Kelvin

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

avatar image
Former Member May 16 at 05:57 AM
0

First stp:

*BDC DATA
PERFORM frm_bdc_data USING:
'X' 'SAPMV50A' '4104',
'' 'BDC_OKCODE' '=VERP_T',
'' 'LIKP-VBELN' gv_delivery_no,

'X' 'SAPLV51G' '6000',
'' 'BDC_OKCODE' '=ENTR',
'' 'V51VE-VHILM(01)' con_vhilm,

'X' 'SAPLV51G' '6000',
'' 'BDC_OKCODE' '=HU_MARKA',

'X' 'SAPLV51G' '6000',
'' 'BDC_OKCODE' '=HUMARKHU',

'X' 'SAPLV51G' '6000',
'' 'BDC_OKCODE' '=HU_VERP',

'X' 'SAPLV51G' '6000',
'' 'V51VE-BRGEW(01)' lv_gross,
'' 'V51VE-TARAG(01)' lv_tare,
'' 'BDC_OKCODE' '=SICH'.

*Call transaction VL32N to creat HU
CALL TRANSACTION con_vl32n USING gt_bdc
MODE con_n
UPDATE con_s
MESSAGES INTO gt_bdcmsgcoll.

Second Step:

* Convert delivery number
CLEAR: lv_vbeln.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = gv_delivery_no
IMPORTING
output = lv_vbeln.

* Carry out goods issue
lv_vbkok-vbeln_vl = lv_vbeln.
lv_vbkok-wabuc = 'X'.
* lv_vbkok-spe_auto_gr = 'X'.
lv_vbkok-wadat_ist = p_pdate.

* Post goods recipt by delivery(Item already packed in HU)
CALL FUNCTION 'WS_DELIVERY_UPDATE'
EXPORTING
vbkok_wa = lv_vbkok
synchron = 'X'
update_picking = 'X'
commit = 'X'
delivery = lv_vbeln
nicht_sperren = 'X'
TABLES
prot = lt_prott
EXCEPTIONS
OTHERS = 0.

In the steps two, raise a error message "No HUs have been transferred for material & & &"

Share
10 |10000 characters needed characters left characters exceeded