09-09-2008 7:51 AM
Hi Gurus,
I have an idoc,
If vendor material number is not correct run the idoc to error.
Please see the code below.
Check the Vendor Material Number is correct one, if not run idoc to error.
select single idnlf
from eina
into lv_idtnr
where matnr = lv_matnr
and lifnr = lv_lifnr
and idnlf = wa_fekpo-idnlf.
if sy-subrc ne 0.
wa_status-uname = sy-uname.
wa_status-status = '51'.
wa_status-docnum = i_control-docnum.
wa_status-msgty = co_err.
wa_status-msgid = co_msgid.
wa_status-msgno = co_msgno.
wa_status-segnum = segment-segnum.
wa_status-segfld = co_field.
wa_status-repid = co_repid.
append wa_status to i_status.
CLEAR wa_status.
endif.
but still IDOC is getting processed. Can you please let me know , how to check this condition and run the idoc to error.
regards
Avi..
09-09-2008 8:58 AM
03-29-2009 5:44 AM