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

Querying pc_payresult values

Former Member
0 Likes
687

Hi,

Please suggest how to capture the values - for period and the start date for period and end date for period as per the values found in pc_payresult.

Regards,

Binay.

1 ACCEPTED SOLUTION
Read only

geetha_k
Active Participant
0 Likes
637

Hi ,

u will check the cluster table PC261.

DATA: BEGIN OF RGDIR OCCURS 100.

INCLUDE STRUCTURE PC261.

DATA: END OF RGDIR.

DATA: RESULT TYPE PAY99_RESULT, " Payroll Result

MY_RT LIKE PC207 OCCURS 0 WITH HEADER LINE.

PERFORM GET_RGDIR.

{

FORM GET_RGDIR.

CALL FUNCTION 'CU_READ_RGDIR'

EXPORTING

PERSNR = V_PERNR

TABLES

IN_RGDIR = RGDIR

EXCEPTIONS

NO_RECORD_FOUND = 1

OTHERS = 2.

IF SY-SUBRC = 0.

*write: 'yes'.

ELSE.

*write: 'no'.

ENDIF.

}

LOOP AT RGDIR WHERE FPBEG GE P_BEGDA AND FPEND LE P_ENDDA.

data move from cluster table to internal table.

ENDLOOP.

2 REPLIES 2
Read only

Former Member
0 Likes
637

U need to get the payroll results as ..

Call function CU_READ_RGDIR to get the results directory

for a particular pernr.

Loop at rgdir where FPBEG = v_FPBEG

and FPEND = v_FPEND.

v_seqnr = rgdir-seqnr.

Endloop.

use this seqnr and pernr and call macro ..

rx-key-pernr = p_pernr

rx-key-seqnr = v_seqnr.

rp-imp-c2-ru.

loop at rt.

*get BETRG based on the required LGART ...

endloop.

Read only

geetha_k
Active Participant
0 Likes
638

Hi ,

u will check the cluster table PC261.

DATA: BEGIN OF RGDIR OCCURS 100.

INCLUDE STRUCTURE PC261.

DATA: END OF RGDIR.

DATA: RESULT TYPE PAY99_RESULT, " Payroll Result

MY_RT LIKE PC207 OCCURS 0 WITH HEADER LINE.

PERFORM GET_RGDIR.

{

FORM GET_RGDIR.

CALL FUNCTION 'CU_READ_RGDIR'

EXPORTING

PERSNR = V_PERNR

TABLES

IN_RGDIR = RGDIR

EXCEPTIONS

NO_RECORD_FOUND = 1

OTHERS = 2.

IF SY-SUBRC = 0.

*write: 'yes'.

ELSE.

*write: 'no'.

ENDIF.

}

LOOP AT RGDIR WHERE FPBEG GE P_BEGDA AND FPEND LE P_ENDDA.

data move from cluster table to internal table.

ENDLOOP.