【SAP】ABAP中submit
程序员文章站
2022-05-18 07:55:13
...
SUBMIT zpprpt1066 WITH sel1 = 'X'
WITH p_werks = i_werks
WITH s_matnrz IN r_matnr
WITH ht = 'X'
EXPORTING LIST TO MEMORY AND RETURN.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = it_memory
EXCEPTIONS
not_found = 1
OTHERS = 2.
IF it_memory[] IS INITIAL.
e_flag = 'N'.
e_mess = '查询没有数据'.
EXIT.
ENDIF.
CALL FUNCTION 'LIST_TO_ASCI'
TABLES
listasci = it_list[]
listobject = it_memory
EXCEPTIONS
empty_list = 1
list_index_invalid = 2
OTHERS = 3.
IF sy-subrc <> 0.
e_flag = 'N'.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4 INTO e_mess.
EXIT.
ENDIF.
上一篇: js计算两个日期之间工作日,去除周末
推荐阅读