Application Development 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: 

update customer address?

former_member537489
Participant
0 Kudos

Dear experts,

I am trying to change two of the fields of the address line in fd02 (like STR_SUPPL1), by function module ADDR_UPDATE and it doesnot work even though I am doing commit work at the end.

The error table ERROR_TABLE was pretty helpful in guiding me to insert the correct mandatory fields but still I cannot see my changes in fields STR_SUPPL1 and STR_SUPPL2...

What is wrong?

Thank you in advance,

Roxani

4 REPLIES 4

former_member194669
Active Contributor
0 Kudos

May be u can use

BAPI_ADDRESSORG_CHANGE

BAPI_CUSTOMER_CHANGEFROMDATA

BAPI_CUSTOMER_CHANGEFROMDATA1

IAC_CUSTOMER_ADDRESS_CHANGE

aRs

0 Kudos

Thank you Ars,

I will check it out tomorrow morning.

Roxani

0 Kudos

Dear Ars,

I dont see the fields i am interested in , in those functions....

STR_SUPPL1 and STR_SUPPL1.

Roxani

alejandro_lpez
Contributor
0 Kudos

Hi Roxani,

You can try using the function module BAPI_ADDRESSORG_CHANGE and use the structure BAPIAD1VL to change the fields STR_SUPPL1 and STR_SUPPL2.

CALL FUNCTION 'BAPI_ADDRESSORG_CHANGE'

EXPORTING

obj_type = 'KNA1'

obj_id = w_objid

obj_id_ext = ' '

context = 1

accept_error = 'X'

save_address = 'X'

TABLES

bapiad1vl = it_bapiad1vl

bapiad1vl_x = it_bapiad1vl_x

RETURN = it_return.

To consult the changes you can use the FM BAPI_ADDRESSORG_GETDETAIL.

Regards,

Alejandro.