Application Development and Automation 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: 
Read only

Finding customer address through FM

Former Member
0 Likes
1,371

is thr any function module thru which we can get the customer address.

Input-Cutomer Code

Ouput- Customer addreds(city,State etc)

is thr any function module thru which we can get the customer address.

Input-Cutomer Code

Ouput- Customer addreds(city,State etc)

4 REPLIES 4
Read only

uwe_schieferstein
Active Contributor
0 Likes
1,128

Hello Dheeraj

Since I do not know what you mean by "customer code" I have to make a few guesses.

If you have a business partner number, the you can use:

- BAPI_BUPA_ADDRESS_GET_NUMBERS

- BAPI_BUPA_ADDRESS_GETDETAIL

If you are looking for debitor, you can use:

- BAPI_CUSTOMER_GETDETAIL2

Regards

Uwe

Read only

anversha_s
Active Contributor
0 Likes
1,128

hi,

chk this sample.

report zxyz_0003.

data: xusr_ad type addr3_val.

call function 'SUSR_USER_ADDRESS_READ'

exporting

user_name = sy-uname

  • READ_DB_DIRECTLY = ' '

importing

user_address = xusr_ad

  • USER_USR03 =

exceptions

user_address_not_found = 1

others = 2.

write:/ xusr_ad-NAME_FIRST, xusr_ad-NAME_last.

If you still want to get form USER_03 structure, you can like this.

report zxyz_0003.

data: xusr_ad type addr3_val.

data: xusr_03 type usr03.

call function 'SUSR_USER_ADDRESS_READ'

exporting

user_name = sy-uname

  • READ_DB_DIRECTLY = ' '

importing

user_address = xusr_ad

USER_USR03 = xusr_03

exceptions

user_address_not_found = 1

others = 2.

write:/ xusr_ad-NAME_FIRST, xusr_ad-NAME_last.

write:/ xusr_03-name1, xusr_03-name2.

Regards,

anver

Read only

Former Member
0 Likes
1,128

Hi,

You can use,

1) READ_KNA1

2) if you know the communication type you can use

C1CE_ADDRESS_READ_FROM_KNA1.

Regards,

Raghavendra

Read only

Former Member
0 Likes
1,128

Hi

VHUMISC_GET_CUSTOMER_DATA, FI_CUSTOMER_DATA, RE_FI_CUSTOMER_DATA, BAPI_CUSTOMER_GETDETAIL1 & BAPI_CUSTOMER_GETDETAIL2, can suit your requirement.

Kind Regards

Eswar