Skip to Content
avatar image
Former Member

CS12

hi all,

I am working on BOM.

The header material is test under which there is test1 under which there is test2.

If u go to CS12 you would find the different levels. I have exploded the BOM using FM " CS_BOM_EXPLOSION ". Now in CS12 you would find the different levels.

I need to print the component number and the object description.

Could any1 pls help me with this.

Thanks

nayan.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Aug 20, 2007 at 04:24 PM

    First goto Table MAST with the Material Number to obtain MAST-stnlr. With stlnr you can co to the STPO Table to get all the BOM Compenets. If the Item is a Material, field IDNRK would contain the Material Master Number. MAKT woudl contain your Description. Keep in mind this would be a Single Level BOM Explosion only. You would need to repeat the Check at each item to determine if there are additional BOM Levels.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Aug 20, 2007 at 04:36 PM

    Hi,

    use the function module CS_BOM_EXPL_MAT_V2

    Regards

    Sudheer

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Aug 20, 2007 at 04:38 PM

    check below code....

    LOOP AT it_matnr.

    REFRESH: it_stb, it_matcat.

    CALL FUNCTION 'CS_BOM_EXPL_MAT_V2'

    EXPORTING

    capid = 'PP01'

    datuv = sy-datum

    mktls = 'X'

    mehrs = 'X'

    mtnrv = it_matnr-matnr

    stlal = p_stlal

    stlan = p_stlan

    stpst = 0

    svwvo = 'X'

    werks = p_werks

    vrsvo = 'X'

    TABLES

    stb = it_stb

    matcat = it_matcat

    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.

    LOOP AT it_stb WHERE postp = c_val_l.

    gf_it_bom_expl-bom_mat = it_matnr-matnr.

    gf_it_bom_expl-bom_comp = it_stb-idnrk.

    gf_it_bom_expl-level = it_stb-stufe.

    gf_it_bom_expl-ojtxp = it_stb-ojtxp.

    APPEND gf_it_bom_expl TO it_bom_expl.

    ENDLOOP.

    ENDLOOP.

    Add comment
    10|10000 characters needed characters exceeded