2006 Mar 27 7:49 AM
Please tell me how to make bapi BAPI_ADDRESSORG_CHANGE or BAPI_ADDRESSORG_SAVEREPLICA save the vendor address data.
I am trying to update the vendor address details using bapi BAPI_ADDRESSORG_CHANGE or BAPI_ADDRESSORG_SAVEREPLICA since the IDoc type CREMAS does not cater for all the vendor address fields in transaction XK01 of FK01.
The BAPI give no error and it returns with an address number, but when I go to transaction I find that it did not update. I call the bapi as follows:
CALL FUNCTION 'BAPI_ADDRESSORG_CHANGE'
EXPORTING
obj_type = 'LFA1'
obj_id = lv_lifnr
OBJ_ID_EXT = ' '
CONTEXT = 1
ACCEPT_ERROR = ' '
SAVE_ADDRESS = 'X'
IV_CHECK_ADDRESS = 'X'
IV_TIME_DEPENDENT_COMM_DATA = ' '
IMPORTING
ADDRESS_NUMBER = lv_address_number
TABLES
BAPIAD1VL = t_bapiad1vl
BAPIADTEL = t_bapiadtel
BAPICOMREM = t_bapicomrem
BAPIAD1VL_X = x_BAPIAD1VL
BAPIADTEL_X = x_BAPIADTEL
BAPICOMRE_X = x_BAPICOMREM
I populate my structures as follows:
t_bapiad1vl-extens_1 = '3278'.
x_bapiad1vl-extens_1 = 'X'.
t_bapiad1vl-house_no = '100'.
x_bapiad1vl-house_no = 'X'.
t_bapiad1vl-str_suppl1 = 'BROADCAST HOUSE'. "Building: street2.
x_bapiad1vl-str_suppl1 = 'X'.
*t_bapiad1vl-extens_1 = '3278'.
*t_bapiad1vl-house_no = '100'.
*t_bapiad1vl-str_suppl1 = 'BROADCAST HOUSE'. "Building: street2.
*
APPEND t_bapiad1vl.
APPEND x_bapiad1vl.
t_bapicomrem-comm_type = 'SSF'.
x_bapicomrem-comm_type = 'X'.
APPEND t_bapicomrem.
t_bapiadtel-extension = '1111'.
x_bapiadtel-extension = 'X'.
t_bapiadtel-telephone = '1111111111'.
x_bapiadtel-telephone = 'X'.
APPEND t_bapiadtel.
lv_lifnr = '0005000102'.
Try calling the function module BAPI_TRANSACTION_COMMIT
after you are done with the process
Sricvathsan
2006 Mar 27 7:59 AM
Try calling the function module BAPI_TRANSACTION_COMMIT
after you are done with the process
Sricvathsan
2006 Mar 27 8:09 AM
Hi Srivathsan Kannan
I am calling the BAPI_TRANSACTION_COMMIT, but it still does not do the update.
2006 Mar 27 8:20 AM
Hi,
Try with this BAPI.
<b>BAPI_BUPA_ADDRESS_CHANGE</b>
Regards
Vijay
2006 Dec 16 11:01 AM
Hi Vijay,
Please help me in the following.
As Vendor/Customer Master dont have all the address fields ( like Street4-5), we use FM BAPI_ADDRESSORG_SAVEREPLICA to overcome this problem.
In my case i have created one Custom load program to upload address data using
BAPI_ADDRESSORG_SAVEREPLICA and then LSMW project to upload rest of the data.
In this case when i upload rest of the data by LSMW using BI standard program ( having NODATA indicator "/" in my source file for the fields already uploaded using BAPI above) , address data which uploaded through FM should get populate automatically (by concept of Central Address management) but in my case <b>for some of the Account Group it is not getting populated,</b> please suggest.
regards
Sonal
2006 Mar 27 8:29 AM
Hi Vijay Babu Dudla
This will not work as my vendor are not created as business partners.
2006 Mar 27 10:22 AM
Hello Geoige,
From the code which u have posted it is not clear if u have also updated table BAPIAD1VL_X & BAPIADTEL_X for the field updateflag. It should be set to U for update.
2006 Mar 27 10:51 AM
Hi Abhijit Dani
I have updated those x structures as well. I discovered that the structure bapiadtel is updating, but bapiad1vl and bapicomrem do not update. Another thing I have noticed is that the bapi only runs successfully if the context field is set to '0001' which is Main vendor address, otherwise it doesn't.
2006 Sep 06 7:26 PM
Make sure you assign following value to the from_date field
zlt_bapiad1vl-from_date = '00010101'.
"this is a standard sap value
append zlt_bapiad1vl to ztt_bapiad1vl.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |