2008 Jul 17 12:03 PM
i want the out put as these fields name , ssn, birthdate ,status and position, by giving a condition where hire date falls between start date and end date .company code ,sart date ,end date are the parameters. These data as been selected from infotypes 0000 , 0001, 0002 .
Reply me as soon as possible its bit urgent .
i want the out put as these fields name , ssn, birthdate ,status and position, by giving a condition where hire date falls between start date and end date .company code ,sart date ,end date are the parameters. These data as been selected from infotypes 0000 , 0001, 0002 .
Reply me as soon as possible its bit urgent .
2008 Jul 17 12:07 PM
Sri,
use below code:
REPORT zpayroll.
TYPE-POOLS : slis.
TABLES: pernr, t001p.",hrpy_rgdir , hrpy_wpbp .
INFOTYPES: 0000,
0001,
0002,
0006,
0007,
0008,
0032,
0065,
0077,
0041,
0069.
START-OF-SELECTION.
* CHECK sy-batch = ''.
* MESSAGE 'Report can only be run in background press F9' TYPE 'I'.
* LEAVE LIST-PROCESSING.
GET pernr.
CLEAR it_output.
CLEAR it_final.
* Read Infotype 0
rp-provide-from-last p0000 space pn-begda pn-endda.
* Get Hire date of Employee
CALL FUNCTION 'RP_GET_HIRE_DATE'
EXPORTING
persnr = pernr-pernr
check_infotypes = '0000'
IMPORTING
hiredate = g_hiredt.
* Read Infotype 1
rp-provide-from-last p0001 space pn-begda pn-endda.
PERFORM get_orgtext.
* Read Infotype 2
rp-provide-from-last p0002 space pn-begda pn-endda.
* Read Infotype 6
rp-provide-from-last p0006 space pn-begda pn-endda.
* Read Infotype 7
rp-provide-from-last p0007 space pn-begda pn-endda.
* Read Infotype 8
rp-provide-from-last p0008 space pn-begda pn-endda.Amit.