‎2011 Mar 10 4:33 AM
Hello I'm developing an ABAP program in order to extend a list of materials from one center (werks) to another (werks). I'm using the BAPI_MATERIAL_GET_ALL to retrieve the material information and after that I'm using the BAPI_MATERIAL_SAVEDATA after making some adjustments to the material information received from the BAPI_MATERIAL_GET_ALL.
How can I know from the information retrieved from the BAPI_MATERIAL_GET_ALL which views to mark when using the BAPI_MATERIAL_SAVEDATA? For example:
e_headdata-basic_view = 'X'.
e_headdata-sales_view = 'X'.
e_headdata-purchase_view = 'X'.
e_headdata-mrp_view = 'X'.
e_headdata-forecast_view = 'X'.
e_headdata-work_sched_view = 'X'.
e_headdata-prt_view = 'X'.
e_headdata-storage_view = 'X'.
e_headdata-quality_view = 'X'.
e_headdata-account_view = 'X'.
e_headdata-cost_view = 'X'.
e_headdata-inp_fld_check = 'X'.
‎2011 Mar 11 12:04 PM
In function BAPI_MATERIAL_GET_ALL check the parameter CLIENTDATA . you will be having field MAT_STATUS which will determine it. Each alphabet in that field represents a view. execute function module SELECTION_VIEWS_FIND passing bildsequenz = 21 and pflegestatus = MAT_STATUS, it will give the views.
‎2011 Mar 11 9:00 AM
Hi,
Have you come out of this issue.. if so means can u share the logic,, even i too struggling this point of view.
‎2011 Mar 11 12:04 PM
In function BAPI_MATERIAL_GET_ALL check the parameter CLIENTDATA . you will be having field MAT_STATUS which will determine it. Each alphabet in that field represents a view. execute function module SELECTION_VIEWS_FIND passing bildsequenz = 21 and pflegestatus = MAT_STATUS, it will give the views.