‎2010 Nov 29 9:25 PM
Hi,
I need to update 'POS outbound profile' field (WRF1- KOPRO) for a store using a FM or a BAPI.
Do you know which one I can use in order to update a site?
Can you please help??
Thanks,
Br
Edited by: yukimai Maio on Nov 30, 2010 12:29 PM
‎2013 Feb 25 12:06 PM
Hi Friends,
When i searched for the same question i ended up with below approach.
Wanted to share/post the answer as it will help others who are searching for the same question.
Answer:
Use Function Module: LOCATION_UPDATE to update field KOPRO in table WRF1.
Example:
CALL FUNCTION 'WRF_READSITEDATA'
EXPORTING
i_werks = '1234' "Give Site number
IMPORTING
xs_sit_data = s_site_data.
IF s_site_data IS NOT INITIAL.
s_wrf_sit_swrf1_old = s_site_data-wrf_sit_swrf1.
s_wrf_sit_swrf1_new = s_wrf_sit_swrf1_old.
s_wrf_sit_swrf1_new-kopro = 'ABCD'.
CALL FUNCTION 'LOCATION_UPDATE'
EXPORTING
i_wrf1 = s_wrf_sit_swrf1_new
i_ywrf1 = s_wrf_sit_swrf1_old.
IF sy-subrc EQ 0.
WRITE: 'Field KOPRO Updated successfully'.
ENDIF.
ENDIF.
Thanks,
Padmashree.TR