Application Development 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: 

Upload HRP1002 Infotype

Former Member
0 Kudos

Hi Gurus,

I am trying to upload the HRP1002.Please tell me how to upload HRP1002 Infotype.

please send any procedure.

thanks..

5 REPLIES 5

Former Member
0 Kudos

Hi,

Check with the FM "HR_IT1002_WRITE_DOCUMENT".

Regards,

Smart Varghese

Former Member
0 Kudos

HI,

You can use eCATT - SAPGUI method to upload the data.

I had the same issue and did this using ecatt.For more details please read this forum

https://www.sdn.sap.com/irj/scn/forums

Please follow this link for ecatt steps for SAPGUI method.

https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/9093bf93-b1e3-2a10-04ba-f9e5c715...

https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/40ce73c1-b7e3-2a10-35bb-da906896...

Former Member
0 Kudos

Hi,

BAPI is the best method to upload the data into SAP..

Advantages:

1. Time saving.

2. Table control handled automatically.

3. easy to use..

Please Use the function module ''RH_OBJECT_DESCRIPTION_WRITE" to create the description record.

Please use the following procedure.

1. Create position object ID(IT1000) using function Module RH_OBJECT_CREATE...

2. Using the generated Object ID generate relation(IT1001) using FM

RH_RELATION_MAINTAIN..

Use the FM RH_RELATION_MAINTAIN in this way,

LOOP AT T_MAINTAIN INTO WA_MAINTAIN.

WA_MAINTAIN-FCODE = 'INSE'.

WA_MAINTAIN-PLVAR = '01'.

WA_MAINTAIN-ISTAT = '1'.

*Relate account to project

IF WA_MAINTAIN-OTYPE = 'O' AND WA_MAINTAIN-SCLAS = 'O'.

WA_MAINTAIN-RSIGN = 'B'.

WA_MAINTAIN-RELAT = '002'.

*Relate position to project

ELSEIF WA_MAINTAIN-OTYPE = 'O' AND WA_MAINTAIN-SCLAS = 'S'.

WA_MAINTAIN-RSIGN = 'B'.

WA_MAINTAIN-RELAT = '003'.

*Relate job to position

ELSEIF WA_MAINTAIN-OTYPE = 'S' AND WA_MAINTAIN-SCLAS = 'C'.

WA_MAINTAIN-RSIGN = 'B'.

WA_MAINTAIN-RELAT = '007'.

*Relate employee to position

ELSEIF WA_MAINTAIN-OTYPE = 'S' AND WA_MAINTAIN-SCLAS = 'P'.

WA_MAINTAIN-RSIGN = 'A'.

WA_MAINTAIN-RELAT = '008'.

ENDIF.

WA_MAINTAIN-ENDDA = '99991231'.

*FM to create relationship

CALL FUNCTION 'RH_RELATION_MAINTAIN'

EXPORTING

ACT_FCODE = WA_MAINTAIN-FCODE

ACT_PLVAR = WA_MAINTAIN-PLVAR

ACT_OTYPE = WA_MAINTAIN-OTYPE

ACT_OBJID = WA_MAINTAIN-OBJID

ACT_ISTAT = WA_MAINTAIN-ISTAT

ACT_RSIGN = WA_MAINTAIN-RSIGN

ACT_RELAT = WA_MAINTAIN-RELAT

ACT_SCLAS = WA_MAINTAIN-SCLAS

ACT_SOBID = WA_MAINTAIN-SOBID

ACT_BEGDA = WA_MAINTAIN-BEGDA

ACT_ENDDA = WA_MAINTAIN-ENDDA

ACT_PROZT = WA_MAINTAIN-PROZT

EXCEPTIONS

MAINTAINANCE_FAILED = 1

OTHERS = 2.

IF SY-SUBRC 0.

  • WRITE : WA_INPUT-OBJID.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

COMMIT WORK.

ENDLOOP.

3. Using FM RH_OBJECT_DESCRIPTION_WRITE create Description(IT1002).

Regards

Pugazhenthi.P

Satyam computer services Ltd

Former Member
0 Kudos

Use FM : RH_INSERT_INFTY to update 1002 ..


DATA: L_PLOG LIKE P1002 OCCURS 1 WITH HEADER LINE.

Populate L_PLOG ... along with 
L_PLOG-TABNR = TABNR. 

CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
VTASK = 'B'
COMMIT_FLG = ' '
OLD_TABNR_NEW_LANGU = 'X'
TABLES
INNNN = L_PLOG
EXCEPTIONS
ERROR_DURING_UPDATE = 1
NO_AUTHORIZATION = 2
REPID_FORM_INITIAL = 3
CORR_EXIT = 4
OTHERS = 5.

use [this|; for more information.

BDC is another approch.

Edited by: shital phadake on May 25, 2009 6:40 PM

Former Member
0 Kudos

Hi Dude,

Use the Below FM for Upload HRP data...


CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
VTASK = 'B'
COMMIT_FLG = ' '
OLD_TABNR_NEW_LANGU = 'X'
TABLES
INNNN = L_PLOG
EXCEPTIONS
ERROR_DURING_UPDATE = 1
NO_AUTHORIZATION = 2
REPID_FORM_INITIAL = 3
CORR_EXIT = 4
OTHERS = 5.