CALL FUNCTION ‘CS_BOM_EXPL_MAT_V2’
EXPORTING
* ALEKZ = ‘ ‘ ” 是否计算耗损
CAPID = ‘PP01’ ” BOM应用
DATUV = sy-datum ” 有效起始日
EHNDL = ‘1’
EMENG = ‘1’ ” 需求数量
MEHRS = ‘X’ ” 多层展开
MMORY = ‘1’ ” 是否使用缓存
MTNRV = imatnr-matnr ” 展开物料号
STLAN = ‘1’ ” BOM用途
WERKS = s_werks-low ” 物料所在工厂
* IMPORTING
* TOPMAT =
* DSTST =
TABLES
STB = stb
* MATCAT =
EXCEPTIONS
ALT_NOT_FOUND = 1
MATERIAL_NOT_FOUND = 3
MISSING_AUTHORIZATION = 4
NO_BOM_FOUND = 5
OTHERS = 9
.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
data: stb LIKE stpox OCCURS 50 WITH HEADER LINE.
原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/18045.html