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 creation

Former Member
0 Likes
480

Hi all,

I have been searching forum for a way to create a bom with bapi. I find this 3 fm, but I cannot understand which is the best for material bom:

1) BAPI_MATERIAL_BOM_GROUP_CREATE

2) CSAP_MAT_BOM_CREATE

3) CSAI_BOM_CREATE

I would like to do with a report what CS01 do.

Can anybody help me?

thanks

Gabriele

2 REPLIES 2
Read only

sergio_cifuentes
Participant
0 Likes
432

Hi Gabrielle, i use this maybe it works for you


CALL FUNCTION 'CS_BOM_EXPL_MAT_V2'
      EXPORTING
        capid                = v_appli
        datuv                = v_date
        mehrs               = 'X'
        mtnrv                = v_matnr
        rndkz                = ' '
        stkkz                = ' '
        stlan                 = v_usage
        stlal                  = v_stlal
        werks                = ti_mast-werks
        nlink                 = 'X'
      IMPORTING
        topmat                = w_topmat
      TABLES
        stb                   = itab_bom
      EXCEPTIONS
        alt_not_found         = 01
        call_invalid          = 02
        material_not_found    = 03
        missing_authorization = 04
        no_bom_found          = 05
        no_plant_data         = 06.

Read only

Former Member
0 Likes
432

CSAP_MAT_BOM_CREATE is the best