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

getting error in payroll data extraction

ranjna_sharma
Explorer
0 Likes
509

hi,

i am extracting payroll data for south africa and used following includes. but i am getting errror " staement RP-IMP-C2-RW .

is not defined ".

plz help me in this , am i misng some includes.

INCLUDE ole2incl.

INCLUDE rpc2cd09. "Cluster CD data definition

INCLUDE rpc2ca00. "Cluster CA Data-Definition

INCLUDE rpppxd00. "Data Definition buffer PCL1/PCL2 Buffer

INCLUDE rpppxd10.

"Common part buffer PCL1/PCL2 "Buffer Handling routine

INCLUDE rpppxm00.

*-- Country Specific Include

include RPC2RWW0. " Cluster SA data definition

*INCLUDE pc2rxin0. "Cluster IN data definition

INCLUDE rpc2rx09.

code is :

form GET_DATA .

CLEAR: rgdir, int_rgdir.

REFRESH: rgdir, int_rgdir.

*-- Read All The Payroll Runs For An Employee

cd-key-pernr = pernr-pernr.

rp-imp-c2-cu.

CHECK rp-imp-cd-subrc EQ 0.

*-- Clear Data

REFRESH: rt.

IF sy-tabix = 1.

SELECT SINGLE ltx FROM t247 INTO gv_month

WHERE spras = 'E'

AND mnr = pn-begda+4(2).

gv_year = pn-begda+0(4).

ENDIF.

  • Read IN Cluster.

LOOP AT rgdir WHERE fpbeg >= pn-begda AND fpend <= pn-endda.

*AND FPPER EQ RGDIR-INPER .

CHECK rgdir-fpper EQ rgdir-inper AND rgdir-oosdate IS INITIAL.

" AND ( FPAER = IPERI ).

MOVE-CORRESPONDING rgdir TO int_rgdir.

APPEND int_rgdir.

CLEAR int_rgdir.

ENDLOOP.

  • Read the last record.

SORT int_rgdir BY seqnr DESCENDING.

READ TABLE int_rgdir INDEX 1.

rx-key-seqno = int_rgdir-seqnr.

rx-key-pernr = pernr-pernr.

RP-IMP-C2-RW .

CHECK RP-IMP-RW-SUBRC EQ 0.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
392

Also use the following include HZAPAYMACRO in your program. This contains the definition of all the macros use for South Africa payroll.

If you are retrieving only the international clusters like RT, CRT ... try using FM HR_PT_READ_PAYROLL_RESULT.

Regards

Ranganath

1 REPLY 1
Read only

Former Member
0 Likes
393

Also use the following include HZAPAYMACRO in your program. This contains the definition of all the macros use for South Africa payroll.

If you are retrieving only the international clusters like RT, CRT ... try using FM HR_PT_READ_PAYROLL_RESULT.

Regards

Ranganath