请教下各位,我批量导入BOM(数据中有些是多重BOM)时的代码是
DATA : t_stpo LIKE stpo_api03 OCCURS 0 WITH HEADER LINE.
DATA : t_stko LIKE stko_api01 OCCURS 0 WITH HEADER LINE.
CALL FUNCTION 'CSAP_MAT_BOM_MAINTAIN'
EXPORTING
material = itab-matnr
plant = itab-werks
bom_usage = itab-bom_usage
valid_from = itab-date
alternative = itab-alternative
i_stko = t_stko
fl_bom_create = 'X'
TABLES
t_stpo = t_stpo.
问题如下:当导入时alternative为1时,是没有问题,再到alternative为2时,就会出现说我对应物料料表已经存在,
请教下,应该怎样解决,谢谢各位?