2009 Apr 24 7:14 AM
Hi friends,
In which table I can find supervisor id & name for an employee(pernr)?
Pls reply.
Thanks in advance.
Hi friends,
In which table I can find supervisor id & name for an employee(pernr)?
Pls reply.
Thanks in advance.
2009 Apr 24 7:16 AM
Hi,
Check Table HRP1001 where u can find ur supervisor PERNR,
with that u can fetch Name of ur super visor from PA0002.
Ram.
2009 Apr 24 7:19 AM
Hi,
Its difficult to gte in one table. Use the logic below
SELECT PERNR
FROM PA0105
INTO TABLE G_T_PA0105
WHERE SUBTY = C_SUBTY AND
BEGDA >= S_BEGEND-LOW AND
ENDDA <= S_BEGEND-HIGH AND
USRID = S_USRID-LOW.
SELECT ORGEH
FROM PA0001
INTO TABLE G_T_ORG_UNIT FOR ALL ENTRIES IN G_T_PA0105
WHERE PERNR = G_T_PA0105-PERNR AND
BEGDA >= S_BEGEND-LOW AND
ENDDA <= S_BEGEND-HIGH.
LOOP AT G_T_ORG_UNIT.
G_T_ROOT_OBJ-OTYPE = '0'.
G_T_ROOT_OBJ-OBJID = G_T_ORG_UNIT-ORGEH.
APPEND G_T_ROOT_OBJ.
CALL FUNCTION 'HRWPC_GET_DIREPS_OF_LEVEL'
EXPORTING
EVAL_DEPTH = '03'
PLVAR = '01'
BEGDA = S_BEGEND-LOW
ENDDA = S_BEGEND-HIGH
TABLES
ROOT_OBJECTS = G_T_ROOT_OBJ
RESULT_OBJEC = G_T_RESULT_OBJ
RESULT_STRUC = G_T_RESULT_STRUC
EXCEPTIONS
NO_OBJECTS_FOUND = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Regards,
Mansi.
2009 Apr 24 7:20 AM
Plz SEARCH in SCN before posting.
[table for supervisor id & name for an employee|https://forums.sdn.sap.com/click.jspa?searchID=25281668&messageID=6401275]
2009 Apr 24 7:28 AM
hi,
u will get it from pa0001-mstbr
SELECT SINGLE ename pernr FROM pa0001
INTO (wa_final-empnm , lv_pernr )
WHERE mstbr = wa_final-employee.
hope this helps u.
2009 Apr 24 8:23 AM
Hi,
I require to have f4 help for supervisor id input field on screen.How can I achieve this..
Pls reply.
Thanks in advance.
2009 Apr 24 8:29 AM
HI,
Use this Fm F4IF_INT_TABLE_VALUE_REQUEST to get F4 help in AT SELECTION-SCREEN On VALUE-REQUEST.
2009 Apr 24 8:32 AM
Hi Hosmath,
Check the below simple code.
DATA:
l_actor_tab TYPE swhactor OCCURS 0 WITH HEADER LINE,
l_ac_container TYPE swcont OCCURS 0 WITH HEADER LINE.
l_ac_container-element = 'ORG_OBJECT'.
l_ac_container-elemlength = '025'.
l_ac_container-type = 'C'.
CONCATENATE 'US' sy-uname INTO l_ac_container-value.
APPEND l_ac_container.
CALL FUNCTION 'SWX_GET_MANAGER'
TABLES
actor_tab = l_actor_tab
ac_container = l_ac_container
EXCEPTIONS
OTHERS = 2.
IF sy-subrc EQ 0.
READ TABLE l_actor_tab WITH KEY otype = 'US'.
IF sy-subrc EQ 0.
g_apuname = l_actor_tab-objid.
ENDIF.
ENDIF.
Regards
Kumar M
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |