2008 Sep 24 9:19 AM
Hi,
I wanna use LSMW for a data migration. Therefore I'm using the BAPI 'SAVEDATA' to transfer material data.
So far I can transfer one material entity with just one unit of measure (UOM) for table MARM.
However, I do have more than one UOM for a material entity. When I look in 'maintain structure relations', there the IDOC segement 'E1BP_MARM' is in the same hierarchy with the head data although N UOM's are requiered for one material entity. How can this work with the BAPI 'BAPI_MATERIAL_SAVEDATA' if I wanna use more than one UOM's?
2008 Sep 24 9:22 AM
Take the data in an internal table and call the BAPI multiple times..
Loop at itab.
call BAPI_MATERIAL_SAVEDATA FM.
Also, call BAPI_COMMIT to commit the data.
endloop.
2008 Sep 24 10:28 AM
Hi,
You can define multiple source structure in step no 2 of LSMW.In upper level structure provide header data fields and in lower level structure you can provide fields related to your UOM.
While defining fields for both source structure provide an identifier for the starting field of both structure.
Now in step no 3 assign header structure to header data segment and lower level structure to segment containing UOM.
In step number 7 select radio button which says for multiple source structure and in next step assign the file to both structure.
In this way you can upload N UOM for a particular material.
Hope this solves your problem.
Regards,
Brajvir