Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Material BOM create in simulation mode

Former Member
0 Likes
845

Hi Guys,

Is there a FM available to simulate material BOM creation? My requirement is to check whether BOM can be created of a material for a set of components (this includes all standard checks e.g. whether components are valid material numbers, those materials are extended to the plant etc) and act accordingly.

3 REPLIES 3
Read only

Former Member
0 Likes
567

Hi,

Any comments? This is rather urgent.

Points assured.

Read only

0 Likes
567

FM : CS_BOM_EXPL_MAT_V2

Read only

Former Member
0 Likes
567

hi sandeep,

We can use fm-CS_BOM_EXPL_MAT_V2.• This FM will explode the material BoM for given material and plant.

Sample code for FM usage :

CALL FUNCTION 'CS_BOM_EXPL_MAT_V2'

EXPORTING

capid = p_appli

datuv = sy-datum

mktls = 'X'

mehrs = 'X'

mtnrv = v_matnr

stlal = p_alter

stlan = p_usage

stpst = p_level

werks = v_werks

TABLES

stb = it_stpox

matcat = it_cscmat

EXCEPTIONS

alt_not_found = 1

call_invalid = 2

material_not_found = 3

missing_authorization = 4

no_bom_found = 5

no_plant_data = 6

no_suitable_bom_found = 7

conversion_error = 8

OTHERS = 9 .

IF sy-subrc IS NOT INITIAL.

*Message " No Bom detials found

LEAVE LIST-PROCESSING.

ENDIF.

ENDFORM. " EXPLODE_BOM

Reward if it is usful,

Thanks,

Srikanth.A