cancel
Showing results for 
Search instead for 
Did you mean: 

Problem in updating infotype 2001

Former Member
0 Kudos

Hi Experts,

While i am updating infotype 2001 , using HR_INFOTYPE_operation FM it giving a error , because it calling a wrong sceen 2000 , instead of 2001 . can anybody can help on this ?

thanks and regards

Renjith MP

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi Dude,

Please note that every absence type is assigned a Screen number in Determine Entry Screen ans Time Constraint classes in table (V_554S_O).

For Absence type that has Quota deduction it has screen number 2001 and one that has no absence deduction should be assigned to screen number 2000.

Hope this resolves your error.

Regards

Seher

Former Member
0 Kudos

hi,

it is the problem reagrding the ABAP -HR so call the tecahnical personal to take care this problem .

RupaPrasad.

Former Member
0 Kudos

HI

check the table V_554S_O for the particular Absece type which u might wrong screen Number

change that field to 2001..

hope this solve your issue

former_member632729
Contributor
0 Kudos

Hi Dude,

Go through the below code for 2002 infotype :


TYPES BEGIN OF text_version.
TYPES   nummer TYPE x.
TYPES END OF text_version.

DATA: PERSONALDATAKEY    LIKE BAPIPAKEY.
DATA: RETURN       LIKE BAPIRETURN1.
DATA: P2002       LIKE P2002.
DATA: PSKEY       TYPE PSKEY.
DATA: IT_TEXT       TYPE HRPAD_TEXT_TAB .
DATA: LINE       TYPE HRPAD_TEXT.
DATA: version       TYPE text_version.
DATA: pcl1       TYPE pcl1.Input Parameters:

PARAMETERS:  PERNR  LIKE PA2002-PERNR  DEFAULT '1004511',
             AWART  LIKE PA2002-AWART  DEFAULT 'LW',
             BEGDA  LIKE PA2002-BEGDA  DEFAULT SY-DATUM,
             ENDDA  LIKE PA2002-ENDDA  DEFAULT SY-DATUM,
             BEGUZ  LIKE PA2002-BEGUZ,
             ENDUZ  LIKE PA2002-ENDUZ.


START-OF-SELECTION.

  CALL FUNCTION 'HR_EMPLOYEE_ENQUEUE'
        EXPORTING 
          number = PERNR
        IMPORTING
          RETURN = RETURN.

  IF RETURN-NUMBER IS NOT INITIAL.
    EXIT.
  ENDIF.

* ADD DATA
  CLEAR: P2002.
  P2002-PERNR = PERNR.
  P2002-SUBTY = AWART.
  P2002-ENDDA = BEGDA.
  P2002-BEGDA = BEGDA.
  P2002-BEGUZ = BEGUZ.
  P2002-ENDUZ = ENDUZ.
  P2002-AWART = AWART.
  P2002-ITXEX = 'X'.

* WRITE DATA 
  CLEAR: RETURN, PERSONALDATAKEY.
  CALL FUNCTION 'HR_INFOTYPE_OPERATION'
         EXPORTING
              INFTY          = '2002'
              NUMBER         = PERNR
              SUBTYPE        = AWART
              VALIDITYEND    = BEGDA
              VALIDITYBEGIN  = BEGDA
              RECORD         = P2002
              OPERATION      = 'INS'
              NOCOMMIT       = ''
              TCLAS          = 'A'
         IMPORTING 
              RETURN         = RETURN
              KEY            = PERSONALDATAKEY
         EXCEPTIONS
              OTHERS         = 0.

  IF RETURN-NUMBER IS INITIAL.
    COMMIT WORK AND WAIT.
  ELSE.
    ROLLBACK WORK.
    EXIT.
  ENDIF.

graziela
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Renjith MP,

Please, could you provide the error code and description?

Thank you,

Graziela Dondoni

Former Member
0 Kudos

Hi

I am getting this error ,

EPG 015 Required screen change cannot be made

Thanks and regards

Renjith MP