‎2008 Jul 04 10:36 AM
hi friends,
How to get supervisor data of a particular employee?
‎2008 Jul 04 10:42 AM
Hi,
First try to read thge value PERNR(personnel number) using this usign FM 'RH_READ_INFTY_1001' we can get the piostion
LOOP AT t_pa0000 INTO fs_pa0000.
CALL FUNCTION 'RH_READ_INFTY_1001'
EXPORTING
AUTHORITY = 'DISP'
WITH_STRU_AUTH = 'X'
plvar = '01'
otype = 'P'
objid = fs_pa0000-pernr
subty = 'B008'
begda = fs_pa0000-begda
endda = fs_pa0000-endda
TABLES
i1001 = t_i1001
OBJECTS =
EXCEPTIONS
nothing_found = 1
wrong_condition = 2
wrong_parameters = 3
OTHERS = 4
.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
APPEND LINES OF t_i1001 TO t_pos.
CLEAR fs_pa0000.
ENDLOOP.
LOOP AT t_pos INTO fs_i1001.
AT FIRST.
WRITE:
/1 'Object Type'(018),
10 'Object id'(019),
20 'Plan version'(020),
30 'Relationship Specification'(021),
40 'Relationship Between Objects'(022),
50 'Start Date'(023),
62 'End Date'(024),
75 'Type of Related Object'(025),
82 'ID of Related Object'(026).
ENDAT.
WRITE:
/ fs_i1001-otype UNDER text-018,
fs_i1001-objid UNDER text-019,
fs_i1001-plvar UNDER text-020,
fs_i1001-rsign UNDER text-021,
fs_i1001-relat UNDER text-022,
fs_i1001-begda UNDER text-023,
fs_i1001-endda UNDER text-024,
fs_i1001-sclas UNDER text-025,
fs_i1001-sobid UNDER text-026.
ENDLOOP.
Reward if helpful.
Best Wishes,
Chandralekha
Edited by: Chandralekha on Jul 4, 2008 11:42 AM