Problem updating Infotype 1208 subtype ALUM

Hi,
My requirement is to update the infotype 1208 subtype ALUM with the Value "YES" when I terminate a employee in PA40.   ( immediately).
I am using the FM - HR_INFOTYPE_OPERATION which doesn't seem to work.
I tried running a BDC for PA30 , but it is not allowing me to edit the employee and says that i am processing him.
I feel this is an issue with locks. But not sure about how to go with.
Are there any standard classes available or any other method to use to update this infotype while terminating.
Regards,
Karan.

1) as suggested by Suresh first check the return table to know exaclty the error mesage.
2) u can update a IT with same values i don think it wil have a problem
3) to me it looks that it is due to PERNR locked ,as when u r updating it first time the pernr is locked and when u r trying to update it again in the same session it must be failing due to pernr looked..
so before using FM to update IT ,use Fm -
CALL FUNCTION 'BAPI_EMPLOYEE_ENQUEUE'
  EXPORTING
    NUMBER        = number .
IMPORTING
  RETURN        =          .
and after tht call FM to update IT and then call below FM to unlock employee-
CALL FUNCTION 'BAPI_EMPLOYEE_DEQUEUE'
  EXPORTING
    NUMBER        = number.
IMPORTING
  RETURN        =          .
this will solve ur probelm .
amit

Similar Messages

  • Problem updating the infotype 1208 subtype ALUM

    Hi,
    My requirement is to update the infotype 1208 subtype ALUM with the Value "YES" when I terminate a employee in PA40. ( immediately).
    I am using the FM - HR_INFOTYPE_OPERATION which doesn't seem to work.
    I tried running a BDC for PA30 , but it is not allowing me to edit the employee and says that i am processing him.
    I feel this is an issue with locks. But not sure about how to go with.
    Are there any standard classes available or any other method to use to update this infotype while terminating.
    Regards,
    Karan.

    Hi,
    try using this method, this will convert the OLD_IMAGE, NEW_IMAGE, parameters into pnnnn table.
    this code is the following class.
    CL_IM_BR_SALARY_INCREASE,
    you need to create your own method, copy the parameters as well.
    method READ_IMAGE .
      FIELD-SYMBOLS: <f> type any.
      DATA: help_prelp TYPE prelp,
            inf_tabname(10).
      data: wa_p0008      type p0008,
            wa_p0734      type p0734.
      concatenate 'WA_P' p_infty into inf_tabname.
      ASSIGN (inf_tabname) TO <f>.
      loop at p_image into  help_prelp
                      where infty eq p_infty and
                            opera eq p_opera and
                            subty eq '0'.
        CLEAR <f>.
        CALL METHOD cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
          EXPORTING
            prelp = help_prelp
          IMPORTING
            pnnnn = <f>.
          append <f> to pnnnn.
      endloop.
    endmethod.
    Message was edited by:
            javier  santana

  • Problem in updating infotype 2001

    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

    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.

  • Updating Infotype 0025 from acustom table....serious problem

    Hi, 
       I'm having a requirement to update Infotype0025 from a custom table.
         Does any REPORT exist already to update Infotype 25 or others from a custom table following time constraint 1 delimiting the older record and creating the new one from the Appraisal date to '12/31/9999'?
       Or any such scenarios faced by experts ?
    Regards,
    Jyoti

    Hi,
    You have to go for a Custom Z-report & use FM
    <b>"HR_INFOTYPE_OPERATION'</b>.
    Hope this helps.
    Thanks,
    Sarika.

  • Error : 'No object identification permitted for infotype 0582, subtype LTA'

    Hi Experts,
                   While executing the program 'HINUINFO_UPDATE'
    i am getting an error 'No object identification permitted for infotype 0582, subtype LTA'.
                   After the approval for LTA claim  is done in ESS i have executed the program 'HINUINFO_UPDATE' to update he infotypes 15 and 582. Infotype 15 is getting created but while creating the infotype 582 system gives the above error message.
                 In the detailed error log system gives the following message.
                    "You attempted to access a data record with the object identification 1. However, according to the Customizing settings, object identifications cannot be used for subtype LTA of infotype 0582".
            Can anybody please assist me how to solve this problem. Helpful answers will be rewarded.
    Thanks and Best Regards,
    Sanoj.

    Hi ,
    Did any one find solution for this ? Please reply how to fix this issue.

  • UPDATING INFOTYPE

    Hi Experts
    I have one problem in updating infotype using
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
    EXPORTING
    INFTY = '2001'
    NUMBER = pernr
    SUBTYPE = subtype
    VALIDITYBEGIN = validitybegin
    VALIDITYEND = validityend
    RECORD = wa_inf_2001
    OPERATION = action "INS,MOD
    IMPORTING
    RETURN = return
    KEY = key
    EXCEPTIONS
    OTHERS = 3.
    This is working fine for first time operation but when i want to overwrite it .
    Is is displaying as page can not be displayed .
    i.e if updating infotype with same veluse for two times
    i.e duplicationg the values then it is showing error .How to solve it
    Thanks
    Prasad

    1) as suggested by Suresh first check the return table to know exaclty the error mesage.
    2) u can update a IT with same values i don think it wil have a problem
    3) to me it looks that it is due to PERNR locked ,as when u r updating it first time the pernr is locked and when u r trying to update it again in the same session it must be failing due to pernr looked..
    so before using FM to update IT ,use Fm -
    CALL FUNCTION 'BAPI_EMPLOYEE_ENQUEUE'
      EXPORTING
        NUMBER        = number .
    IMPORTING
      RETURN        =          .
    and after tht call FM to update IT and then call below FM to unlock employee-
    CALL FUNCTION 'BAPI_EMPLOYEE_DEQUEUE'
      EXPORTING
        NUMBER        = number.
    IMPORTING
      RETURN        =          .
    this will solve ur probelm .
    amit

  • Updating infotypes

    Hi Experts
    I have one problem in updating infotype using
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
            EXPORTING
              INFTY                  = '2001'
              NUMBER                 = pernr
              SUBTYPE                = subtype
              VALIDITYBEGIN          = validitybegin
              VALIDITYEND            = validityend
              RECORD                 = wa_inf_2001
              OPERATION              = action  "INS,MOD
          IMPORTING
             RETURN                  = return
             KEY                     = key
          EXCEPTIONS
             OTHERS           = 3.
    This is working  fine for first time operation but when i want to overwrite it .
    Is is displaying as page can not be displayed .
    i.e if  updating infotype with same veluse for two times
    i.e duplicationg the values then it is showing error .How to solve it
    Thanks
    Prasad

    <i>This is working fine for first time operation but when i want to overwrite it .
    </i>
    To Insert, you need to pass the action 'INS'
    To Modify action needs to be 'MOD'
    <i>ts is displaying as page can not be displayed .</i>
    To get the exact error message, please do the following settings in IE Browser:
    Tools -->Internet option--> Advanced(Tab) uncheck the "Show Friendly HTTP error messages".
    Raja T

  • Error while updating infotype using HINUINFO_UPDATE

    Hi All,
    While executing the program 'HINUINFO_UPDATE'
    i am getting an error 'No object identification permitted for infotype 0582, subtype LTA'.
    After the approval for LTA claim is done in ESS i have executed the program 'HINUINFO_UPDATE' to update he infotypes 15 and 582. Infotype 15 is getting created but while creating the infotype 582 system gives the above error message.
    In the detailed error log system gives the following message.
    "You attempted to access a data record with the object identification 1. However, according to the Customizing settings, object identifications cannot be used for subtype LTA of infotype 0582".
    Helpful answers will be rewarded .

    Solved by SAP

  • Need a help to Update Infotype.....

    Hi Experts,
    *am developing HR-ABAP Report inthat, i have data in 2 internal tables, through these (itabs) i want to*
    *insert the data into 2 Ztables(Respective tables) and then i want to Update one Custom Infotype.*
    how can i procedure for this? is there any FM to update Infotype....
    Thanks in Advance,
    sudeer.

    The best way is to use HR_INFOTYPE_OPERATION function module in your program.
    Sample code:
          call function 'HR_INFOTYPE_OPERATION'
            exporting
              infty         = p0082-infty
              number        = p0082-pernr
              subtype       = p0082-subty
              validityend   = p0082-endda
              validitybegin = p0082-begda
              record        = p0082
              operation     = 'INS'
              tclas         = 'A'
              dialog_mode   = '0'
            importing
              return        = return
              key           = key.
         capture error messages
          if return-type = 'E'.
            concatenate 'Sub Type:' p0082-infty into messtab-tcode.
            move return-message to messtab-param.
            append messtab. clear messtab.
          endif.
    You can use it for modifying the record also.

  • Standard programs to upload / update infotypes

    Please provide updates for this question:
    What are the standard SAP programs to update infotypes ( Ex: 001 / 002 / 003 ) .
    I will be uploading data from legacy system ( Excel / Text file ) and would like to use standard programs
    before going ahead with BDC .
    Thanks
    Rohan

    Please provide updates for this question:
    What are the standard SAP programs to update infotypes ( Ex: 001 / 002 / 003 ) .
    I will be uploading data from legacy system ( Excel / Text file ) and would like to use standard programs
    before going ahead with BDC .
    Thanks
    Rohan
    Hi Rohan ,
         you can update you infotype using 'HR_INFOTYPE_OPERATION' function module .
    1)   transfer all your excel data  into internal table .
    2)   loop at internal table
    3)  fill all the required field of that infotype .
    4) lock table
    5) call that functuion module .
    6) unlock table
    for this fallow the below code...
    DATA: it_p0169 TYPE STANDARD TABLE OF pa0169 WITH HEADER LINE.  (make internal table according to your requirment)
    DATA: wa_p0169  TYPE p0169.
    LOOP AT it_file
          v_eeamt = it_file-pct_gross.
    *Pre-Tax Contribution Percentage
          v_eepct = v_eeamt / 10.
          v_begda = it_file-datchngd .
    *Appending into header (these all are the required filed in my case )
         it_p0169-eeamt =  v_eeamt.
          it_p0169-begda =  v_begda.
          it_p0169-eepct =  v_eepct.
          it_p0169-bplan =  v_bplan .
          CLEAR wa_p0169.
          MOVE-CORRESPONDING it_p0169 TO wa_p0169.
          wa_p0169-INFTY = '0169'.    (not forget to pass infotype no in the header )
    CONSTANTS: c_action_ins  TYPE pspar-actio VALUE 'MOD',   (it can be also COP for Copy , DEL for Delete , DIS for Display , MOD to Change , LIS9 to  Delimit , INS to Create )
               c_infty_0169  TYPE prelp-infty VALUE '0169'.
    DATA: it_return  TYPE bapireturn1. (as it is )
    DATA: it_return  TYPE bapireturn1.
      CALL FUNCTION 'BAPI_EMPLOYEE_ENQUEUE'
        EXPORTING
          number = p_pernr
        EXCEPTIONS
          OTHERS = 1.
      IF sy-subrc <> 0.
         RAISE enqueue_FAILED.
      ENDIF.
      CALL FUNCTION 'HR_INFOTYPE_OPERATION'
      EXPORTING
        infty                  = c_infty_0169
        number                 = p_wa_0169-pernr
        SUBTYPE                = '401K'
        OBJECTID               =
        LOCKINDICATOR          =
        validityend            = p_wa_0169-endda
        validitybegin          = v_begda1
        RECORDNUMBER           =
        record                 = p_wa_0169
        operation              = c_action_ins
        TCLAS                  = 'A'
        DIALOG_MODE            = '0'
        NOCOMMIT               =
        VIEW_IDENTIFIER        =
        SECONDARY_RECORD       =
      IMPORTING
        return                 = it_return.
       if it_return-MESSAGE is not initial .
         delete it_file .
       endif.
    commit work .
      CALL FUNCTION 'BAPI_EMPLOYEE_DEQUEUE'
        EXPORTING
          number = p_pernr
        EXCEPTIONS
          OTHERS = 1.
      IF sy-subrc <> 0.
         RAISE DEQUEUE_FAILED.
      ENDIF.
    Enjoy
    Priyank

  • Delimit Infotype 0105 Subtype 0001

    Hi All
    I am new to ABAP so need help.
    We need to delimit Infotype 0105 subtype 0001 records.
    I tried vai a number of ways but facing issues in someway or the other.
    When I try to do the same via FM: BAPI_HRMASTER_SAVE_REPL_MULT, it creates a new entry for the same record with end validity day as system date (the old record which has end validity date as 31.12.9999 remains).
    When i try to do the same via FM: BAPI_EMPLCOMM_DELIMIT, it throws an error 'EPG                  009No data stored for 0105 in the selected period' even though the record exists.
    CALL FUNCTION 'BAPI_EMPLCOMM_DELIMIT'
      EXPORTING
        employeenumber       = '00000049'
        subtype              = '0001'
        objectid             = 'P'
        lockindicator        = ''
        validitybegin        = '20100701'
        validityend          = '99991231'
        recordnumber         = '000'
        delimit_date         = '20120219'
    *   NOCOMMIT             =
    IMPORTING
       RETURN               = return.
    *   EMPLCOMMKEY          =
    Not sure how to go about it. I searched the forum which suggested to use Function Modules, but even then the issue isn't getting resolved.
    Please help.
    Martin

    Hi
    Your problem is the parameter OBJECTID It doesn't make sense to pass a 'P'.
    Other than that, you just have to lock and unlock the Personnel Number accordingly.
    Regards
    data: return type BAPIRETURN1.
    CALL FUNCTION 'BAPI_EMPLOYEE_ENQUEUE'
      EXPORTING
        number        = '00000224'
    * IMPORTING
    *   RETURN        =
    CALL FUNCTION 'BAPI_EMPLCOMM_DELIMIT'
      EXPORTING
        employeenumber       = '00000224'
        subtype              = '0001'
        objectid             = ''
        lockindicator        = ''
        validitybegin        = '20070101'
        validityend          = '99991231'
        recordnumber         = '000'
        delimit_date         = '20120219'
    *   NOCOMMIT             =
    IMPORTING
       RETURN               = return.
    *   EMPLCOMMKEY          =
    BREAK-POINT.
    CALL FUNCTION 'BAPI_EMPLOYEE_DEQUEUE'
      EXPORTING
        number        = '00000224'
    * IMPORTING
    *   RETURN        =

  • How to update infotype 0006

    Hello,
    I want to update infotype 0006.
    I tried the things in following way using 'HR_INFOTYPE_OPERATION' function.
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
        EXPORTING
          INFTY                       = '0006'
          NUMBER                   =  PERNR
          SUBTYPE                  =  '1'
          VALIDITYEND           = IT_PA0006-ENDDA
          VALIDITYBEGIN        = IT_PA0006-BEGDA
          RECORD                   = ls_p0006
          OPERATION              = 'CHANGE'
         TCLAS                      = 'A'
          nocommit      = ''
          dialog_mode   = '0'
        IMPORTING
          RETURN                   = RETURN.
    Function was executed successfully but there was no updation in the record.
    Thanks in advance.

    ****Data declaration
    Return Table for ENQUEUE - DEQUEUE messages
    DATA: zreturn TYPE bapireturn1,
          user TYPE sy-uname.
    DATA: wa_0001 TYPE p0001.
    ****Lock the pernr for editing
              CALL FUNCTION 'HR_EMPLOYEE_ENQUEUE'
                EXPORTING
                  number       = pernr
                IMPORTING
                  return       = zreturn
                  locking_user = user.
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
                  EXPORTING
                    infty                  = '9009'
                    number                 = wa_0001-pernr
                   validityend            = wa_0001-endda
                   validitybegin          = wa_0001-begda
                    record                 = wa_0001
                    operation              = 'MOD'                  "It can be 'INS' for insert or 'DEL' for delete
                 IMPORTING
                   return                 = zreturn
    *******Unlock the Pernr
                CALL FUNCTION 'HR_EMPLOYEE_DEQUEUE'
                  EXPORTING
                    number = pernr
                  IMPORTING
                    return = zreturn.
    Hope this will help you.
    Regards,
    Aniruddha

  • Time constraint of Infotype 0006 subtype 1 and 2

    Hi All,
    Currently the TC of infotype 0006 subtype 1 is 1.
    I have changed it to 2, so that the gaps are there but no overlapping.
    However, when I go in SAP and create a new record, its delimiting the previous record. But if I click on change button, its overwriting the original record instead of delimiting it.
    Please advise what can be done regarding the same.

    So that means, whenever an employee updates his address from the front end, the create address standard BAPI should be fired to update the data in R/3.
    This will delimit the previous record, since I have maintained TC as 2 for subtype 1 and 2.
    Please correct me if I am wrong.

  • Class to update infotype

    Hi friends,
    Can you please give the details of class(not HR_INFOTYPE_OPERATION) for updating infotypes?
    Thanks in advance,
    Anu

    Hi Anu,
    If "Class " mentioned by you related to time constrins,
    A time constraint indicates whether more than one infotype record may be available at one time. The following time constraint indicators are permissible:
    1: An infotype record must be available at all times. This record may have no time gaps. You may not delete the record last stored on the database because all records of this infotype would otherwise be deleted.
    2: Only one record may be available at one time, but time gaps are permitted.
    3: Any number of records may be valid at one time, and time gaps are permitted.
    Other possible time constraint indicators are as follows:
    A: Only one record may ever exist for this infotype. It is valid from 01/01/1800 to 12/31/9999. Splitting is not permissible.
    View V_T582B Infotypes Which are Created Automically controls whether the system automatically creates the infotype record for an employee hiring or an applicant data entry action.
    Infotypes with time constraint A may not be deleted.
    B: Only one record may ever exist for this infotype. It is valid from 01/01/1800 to 12/31/9999. Splitting is not permissible.
    Infotypes with time constraint B may be deleted.
    T: The time constraint varies depending on the subtype.
    Z: Refers to time management infotypes. The time constraint for these infotypes depends on the time constraint class defined in view V_T554S_I Absence: General Control. Collision checks are defined in view V_T554Y Time Constraint Reaction.

  • How to update infotype 0712 in the background

    I amd working on a web dynpro applicaiton for PA action request and process action in the background. We have manu concurrent employees. When the main assignemnt is terminated, I need to switch the main pernr to another pernr. I sue HR_INFOTYPE_OPERATION to update other infotypes with no problem, but it does not work with info type 0712. I step through in debugger, see HR_INFOTYPE_OPERATION run though without erro, but IT0712 does not show the update.
    What other tool can I used to update infotype 0712 and 0171?
    Anna

    Hi Anna,
                  Have you tested the IT0712 by manually updating?
    if so try with bdc recording and run in foreground mode.
    if the same hits in IT0712 or 0171.
    use the same with no screen mode.
    don't use the HR_infotype_operation FM
    it will help you.
    cheers...,
    By,
    Vijay.

Maybe you are looking for

  • Problemas ICMS s/ frete

    Bom dia, Segue a todos a explicação do meu problema: O meu cliente alega que possui diferentes alíquotas de ICMS sobre o frete, para um único origem x destino. De acordo com ele, essa diferenciação dá-se ao fato de o cliente ser um consumidor final o

  • How do I get Google search bar results to open in a new tab instead of the current tab?

    When I use the Google search box, I would like the search results to open in a new tab instead of the current tab.

  • How to use HtmlDataTable in JSF

    Hi, I am going to use HtmlDataTable in a bean. The scenario like this: User submit a symbol (a String) then get stock history information corresponding to this symbol. I put the stock history information in an Arraylist, every element of this Arrayli

  • Configuring a printer to a new router

    I just recently got a new router supplied through my service provider. I have a wireless HP Deskjet3050A printer. and since getting the new router i cant print. It says that everything is good and ready to print but it doesnt do anything when I click

  • How do I enable hardware acceleration in an air exe?

    I have a Stage3d game compiled as a windows bundle (exe) using adt -target bundle. Users download it from Steam and have no idea it's even running Adobe AIR. The problem is that if the user has manually disabled hardware acceleration in Firefox, it w