cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI_MATERIAL_SAVEDATA

rahul2000
Contributor
0 Kudos

Dear all,

I want to change Purchasing Group -EKGRP

MRP Controller -DISPO

INHOUSE PRDN TYPE-DZEIT

Planned Delivery-PLIFZ

Planning stratergy group-STRGR

USING BAPI_MATERIAL_SAVEDATA.Is this possible and how?

i am trying to use bapi for the first time.

Can any one plz send me some sample code

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Chk this thread for sample code.

Former Member
0 Kudos

Hi,

In this BAPI, first update all the important datas for the material

example header data , client data etc.

Then in plant data, we have purchasing group, mrp controller,

inhouse prodn type, planned delivery, planning strategy grp.

Update the values.

Ex:

check whatever views you need.

wa_headdata-material = l_matnr.

wa_headdata-matl_type = wa_xyz-mtart.

wa_headdata-basic_view = 'X'.

wa_headdata-sales_view = 'X'.

wa_headdata-purchase_view = 'X'.

wa_headdata-mrp_view = 'X'.

wa_headdata-work_sched_view = 'X'.

wa_headdata-storage_view = 'X'.

wa_headdata-warehouse_view = 'X'.

wa_headdata-quality_view = 'X'.

wa_headdata-account_view = 'X'.

wa_headdata-cost_view = 'X'.

*Updating plant data

wa_plantdata-pur_group = ekgrp.

wa_plantdata-mrp_ctrler = dispo.

wa_plantdata-plnd_delry = plifz.

wa_plantdatax-pur_group = 'X'.

wa_plantdatax-mrp_ctrler = 'X'.

wa_plantdatax-plnd_delry ='X'.

CALL FUNCTION 'BAPI_MATERIAL_SAVEDATA'

EXPORTING

headdata = wa_headdata

clientdata = wa_clientdata

clientdatax = wa_clientdatax

plantdata = wa_plantdata

plantdatax = wa_plantdatax

AND so on.

Hope this is fine.

Regards,

Sundaressh