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

System component for last name

Former Member
0 Likes
868

Is there a system component that gives the user name and his/her last name..... can anyone help please.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
837

HI Shaheen,

There are no system field which directly give the first/last name for the user.

you have to use the sytem fiel SY-UNAME to get the other user details.

select single *

from USR03

where BNAME = sy-uname.

usr03-NAME1, usr03-NAME2, usr03-NAME4 will have the names of the user.

Regards,

Ravi

Is there a system component that gives the user name and his/her last name..... can anyone help please.

5 REPLIES 5
Read only

Former Member
0 Likes
837

Hi,

SY-UNAME field gives the User name .

using the User name you can get the last name/ first name in PA0002 info type

or You can get in the user related tables USR01/02/03 etc.

Reward if useful,

regards,

Anji

Read only

0 Likes
837

Thanks but I'm not using HR report, I'm using normal report.... I used uname and it's giving me the user name only.

Read only

0 Likes
837

Hi,

Check in the table USR03 using Sy-Uname.

regards,

Anji

Read only

Former Member
0 Likes
838

HI Shaheen,

There are no system field which directly give the first/last name for the user.

you have to use the sytem fiel SY-UNAME to get the other user details.

select single *

from USR03

where BNAME = sy-uname.

usr03-NAME1, usr03-NAME2, usr03-NAME4 will have the names of the user.

Regards,

Ravi

Read only

Former Member
0 Likes
837

You can also use this FM to get the NAME1 and NAME2 of the user

<b>TMS_WBO_READ_USER_ADDRESS</b>