Updating infotype from userexit of PA30

in transaction PA30 when i create data in one infotype (say 0033) i want to create data in another infotype (0019)
which user-exit do i need to use for the same
can anyone please help me regarding the same
thanks in advance

I am BADI HRPAD00INFTY (method IN_UPDATE) for PA30 TC and changing
the addresss field infotype, in GF7/500 system.
In BADI, there are two importing parameter which i am reffering to -
1. OLD_IMAGE
2. NEW_IMAGE.
In the above structures the field DATA1 contains the old values and new
values(in respective structures) of the address. My requirement is that
i want to get the old values and new values in proper structure format
whereas the field DATA1 contains the values in string format.
I am trying to read the values through data1 with the help of offset
keyword but there is a encrypted symbol that is coming in the
field DATA1 because of which it is giving me a dump.
So kindly do the needful ASAP.
Reagrds, Ranveer

Similar Messages

  • Update infotype from user exit

    Hi,
    My requirement is to update a infotype from a user exit. I have a internal table with some records created in the user exit pbas0001. Now i need to update these records in the infotype 2001(absences). I tried using HR
    INFOTYPEOPERATIONS directly from the user exit and it didn't work. If i create a include program and create a subroutine within the include program and call it in the user exit still i am getting a error message. How can update the infotype from the user exit.
    Can someone send the example code for how to export the internal table from the user exit and import it in another program and update the infotype from that prgm.

    Put the entire code in another Report & SUBMIT that report from the User exit.. this will isolate the two work processes & the Z table should get updated..
    ~Suresh

  • Update HRMD_A infotypes from inbound Idoc

    Hi again all,
    I am trying to send inbound HRMD_A06 idocs to SAP to update infotypes for employees. The idocs are received by SAP, processed by the correct application and stored in the database for the employee. But the values already stored in the infotypes should be delimited based on the new data, and it is not!
    The new value, ie. IT0105 subty 0010 (email) has the previous values:
    BEGDA: 20040101
    ENDDA: 99991231
    INFTY: 0105
    SUBTY: 0010
    USRTY: 0010
    USRID_LONG: [email protected]
    The idoc sent to SAP contains the following values (which are stored successfully in the database):
    BEGDA: 20050201
    ENDDA: 99993112
    INFTY: 0105
    SUBTY: 0010
    USRTY: 0010
    USRID_LONG: [email protected]
    The new values are stored correctly for the correct employee, but the previous values are not delimited! SAP only adds the new value to the list of infotypes for the employee. The previous values should be set so ENDDA = 20050131.
    Currently there is no way to know which value is the valid one, as both values are currently valid. We are using time constraint 2 (only one value valid at any time), but this seems not to be functioning.
    Does anyone have any experience with this?
    Any help is highly appreciated.
    Br,
    Kenneth

    Hi Senthil,
    That was apparently a typo from me... The ENDDA is set as 99991231. But according to OSS note 134085 the inbound HRMD_A idocs are bypassing all consistency checks and time constraint checks. But I have managed to overwrite the previous value if the new BEGDA and ENDDA at least covers the previous BEGDA and ENDDA, and BEGDA >= hire-date. Even though I can't delimit records, I can live with this solution.
    Thanks for your reply.
    -Kenneth

  • 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.

  • Getting error while Updating Infotype 0377

    Hi All,
    I am using FM 'HR_ECM_INSERT_INFOTYPE' for updating data from an excel file in infotype 0377 but i am getting this error 'Entry   VSEL   does not exist in T5UBA (check entry)'. This is coming due to the foreign key validation on the fields BPLAN & LEVL1. So the records are not getting updated in the infotype. But when i am trying to create a record with same data manually through PA30 its getting created. Can you please tell me which FM is being used for infotype updation in PA30. If i use the same FM, may be my issue gets resolved.Thanks.
    Regards,
    Arpita.

    Please find the code below:
    CREATE OBJECT v_message_handler.
        CLEAR: v_is_ok.
        CALL FUNCTION 'HR_ECM_INITIALIZE_BUFFER'
          EXPORTING
            message_handler = v_message_handler.
        CALL FUNCTION 'HR_ECM_ENQUEUE_PERNR'
          EXPORTING
            pernr           = wa_p0377-pernr
            message_handler = v_message_handler
          IMPORTING
            is_ok           = v_is_ok.
        CLEAR v_error_mssg.
        IF v_is_ok IS INITIAL.
          PERFORM get_error_msg USING v_message_handler
                                      wa_p0377-pernr
                                CHANGING v_error_mssg.
          v_tot_err = v_tot_err + 1.
        ELSE.
    *      CALL FUNCTION 'HR_ECM_INSERT_INFOTYPE'
    *        EXPORTING
    *          pnnnn           = wa_p0377
    *          message_handler = v_message_handler
    *        IMPORTING
    *          is_ok           = v_is_ok.
    *      IF  v_is_ok IS INITIAL.
    *        PERFORM get_error_msg USING v_message_handler
    *                                    wa_p0377-pernr
    *                              CHANGING v_error_mssg.
    *        v_tot_err = v_tot_err + 1.
    *      ELSE.
    *        v_tot_suc = v_tot_suc + 1.
    *        CLEAR wa_error.
    *        wa_error-cnt = '1'.
    *        wa_error-pernr = wa_p0377-pernr.
    *        wa_error-desc = 'Data Successfully Uploaded'.
    *        APPEND wa_error TO i_error.
    *      ENDIF.
          CALL FUNCTION 'HR_INFOTYPE_OPERATION'
            EXPORTING
              infty            = '0377'
              number           = wa_p0377-pernr
    *         SUBTYPE          =
    *         OBJECTID         =
    *         LOCKINDICATOR    =
              validityend      = wa_p0377-endda
              validitybegin    = wa_p0377-begda
    *         RECORDNUMBER     =
              record           = wa_p0377
              operation        = 'INS'
    *         TCLAS            = 'A'
    *         DIALOG_MODE      = '0'
    *         NOCOMMIT         =
    *         VIEW_IDENTIFIER  =
    *         SECONDARY_RECORD =
            IMPORTING
              return           = v_return
              key              = wa_perdatakey
            EXCEPTIONS
              OTHERS           = 0.
          IF sy-subrc = 0.
            "Success
          ENDIF.
          IF v_error_mssg IS INITIAL.
            CALL FUNCTION 'HR_ECM_FLUSH_INFOTYPE'
              EXPORTING
                nocommit        = ' '
                message_handler = v_message_handler.
          ENDIF.
          CLEAR v_is_ok.
          CALL FUNCTION 'HR_ECM_DEQUEUE_PERNR'
            EXPORTING
              pernr           = wa_p0377-pernr
              message_handler = v_message_handler
            IMPORTING
              is_ok           = v_is_ok.
        ENDIF.
        CLEAR wa_p0377.
      ENDLOOP.
      FREE i_it0377.           "Clearing the internal table
    ENDFORM.                    " SELECT_UPLOAD_DATA
    Actually in this program i am fetching values from an excel file & updating them into IT0377.Yes the IT171 is maintained for those employees. CAn you please guide me as how to resolve this issue? If need more info, pls let me know.Thanks.

  • Update infotype 0032 in user exit ZXPADU02

    Hi All,
    I have the following requirement.
    Telephone extension number is stored in IT0105 and IT0032. When the extension number is updated through ESS, this is stored in IT0105 but it does not update IT0032 which is displayed in MSS.
    I need to update infotype 0032 based on the data in 0105.
    I thought I could update infotype 0032 in userexit ZXPADU02 whenever infotype 0105 was saved using the function module HR_INFOTYPE_OPERATION but it is not working for me.
    Any help would be appreciated.
    Elaine

    You have to make the function call a separate unit of work.One other option is to put the function call in a report & SUBMIT it from the User exit.
    ~Suresh

  • Standard programs to 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

    Hi,
    I checked out the program you stating.......
    In that program itself if you check the documentation its given how to add in fields.......
    You can use report RPUSTD00 to transfer master data from your old HR system.
    The dataset to be transferred must be stored in a sequential file. The file is stored under the name specified in the "logical file name" field (for more information on logical file names, read the IMG section entitled Additional client-dependent file name maintenance).
    The report reads this dataset and creates a batch input session for transaction PA30.
    The data description of your old record is defined according to the structure HRDATASET. If this structure does not meet your requirements, create the structure CI_HRDATAS in the ABAP Dictionary. In this structure, you can store the infotype fields to which data should be transferred. Make the necessary changes in RPUSTD00.
    Example
    If the include CI_HRADATAS contains the field F1 which is to be assigned to the infotype nnnn, add the following ABAP statements to FORM Dnnnn:
      CLEAR BDCDATA.
      BDCDATA-FNAM = 'Pnnnn-F1'.
      BDCDATA-FVAL =   SATZ-F1.
      APPEND BDCDATA.
    If the FORM Dnnnn does not exist for your infotype nnnn, copy FORM D0008 to FORM Dnnnn. Replace the 0008 by your infotype number:
    FORM Dnnnn.
      CLEAR BDCDATA.
      BDCDATA-PROGRAM  = 'MPnnnn00'.
      BDCDATA-DYNPRO   = '2000'.
      BDCDATA-DYNBEGIN = 'X'.
      APPEND BDCDATA.
      CLEAR BDCDATA.
      BDCDATA-FNAM = 'Pnnnn-F1'
      BDCDATA-FVAL = SATZ-F1
      APPEND BDCDATA.
      CLEAR BDCDATA.
      BDCDATA-FNAM = 'BDC_OKCODE'.
      BDCDATA-FVAL = '=UPD'.
      APPEND BDCDATA.
    ENDFORM.
    The FORM Dnnnn is called directly after FORM D0008; see the ABAP statement indicated as "<------ INSERT in the following (starting at line 1730 in the standard system):
      LOOP AT INFTAB.
        CASE INFTAB.
    Include all infotypes in your action *
         WHEN '0002'. PERFORM D0002.
         WHEN '0001'. PERFORM D0001.
         WHEN '0006'. PERFORM D0006.
         WHEN '0007'. PERFORM D0007.
         WHEN '0008'. PERFORM D0008.
         WHEN 'nnnn'. PERFORM Dnnnn.         "<------ INSERT
         WHEN OTHERS. WRITE: / 'Infotype not included:' (008), INFTAB.
                       STOP.
       ENDCASE.
    ENDLOOP.
    Parameter DSLOGNAM
    Logical file name
    Parameter MAPNAME
    Session name
    Definition
    Enter any name for the session to be created.

  • Updating infotype 1007

    Hello experts,
    I need to update the IT 1007 marking a position as Vacant.
    Is this can be done using a Function Module? like the one that updates infotype in the PA30 (HR_INFOTYPE_OPERATION) ?
    Thanks in advance for your help,
    ArepaKing

    Dear King,
    Not much sure but kindly have a look at function module :-
    RH_UPDATE_INFTY
    Short Text
    Change infotype records
    Functionality
    With this function module you can change multiple infotype records for OM objects from Personnel Planning database tables (HRPnnnn). The infotype tables of the table parameter INNNN must all have the structure Pnnnn (logical structure for the infotype nnnn). The records you want to change must exist in the Personnel Planning database tables. If not, this triggers the exception ERROR_DURING_UPDATE.
    Might be other members can have some more better ideas as well.
    Hope this helps.
    Kindly reward in case useful.
    Regards & Thanks,
    Darshan Mulmule

  • Is it possible to make a call to an Infotype from an ABAP program?

    Dear friends,
    I created a new infotype 9*** using transaction pm01 and it works fine. What i need to do is to make a call to this infotype from an abap program without going through transaction pa30. Is it possible to do that? Thank you in advance.
    Sincerely,
    hajar

    Hi,
    The HR_MASTERDATA_DIALOG might need some tweaking.. we use a custom Program on the lines of SAP's
    'perform rp_infotyp(sapfp50g)'  that is more user friendly.. let me know if u need more info..
    Good Luck,
    Suresh Datti

  • HRMD_A07 Idoc to update InfoType 0014 does not delimit existing PA0014 rec

    In ECC 6.0, we are using HRMD_A07 Idoc to update infotype 0014 using update data received from a third party application. In XI, I am creating the Idoc with Update Code "U" with E1PLOGI, E1PITYP and E1P0014 segments. E1P0014 holds the data for the latest record.
    If I directly pass the Idoc thru ALE layer, It creates records for the new date range on E1P0014 segment, but does not delimit the previous record by changing its end date. This results in two records in PA0014 with end date of 12/31/9999 - which is wrong.
    I also tried using a wrapper FM to create additional segments in the Idoc representing the existing record in PA0014, with the end date being delimited to incoming record's beg. date minus 1.
    This also results in just creating two additional records in PA0014 corresponding to the two segments in Idoc while existing record in PA0014 stays intact resulting in two records with end date 12/31/9999.
    I also experimented with setting the lock indicator (PA0014-SPRPS) but that also does not result in delimiting the existing record.
    Am I missing something? Is there a piece of config that controls this?
    Regards,
    The time constraint on 0014 is "2"

    Hi Jon and Ashish,
    I too am facing the same issue that the new IDOC is not delimiting the previous record.
    Can you explain how did u get over you issue.
    I'm maintaining the same dates in E1PITYP and in E1P0014.
    Thanks,
    Jilly

  • Updating InfoType 0001 in ABAP

    Our parent company is passing different begin and end dates from Infotype 0001 to our HR system. In our system an employee would have a start date of 3/1/2005 but our parent company has the same employee in there system as a start date of 1/1/2008. I was looking at using user exit EXIT_SAPLRHA0_003 to capture these and add the parent companies dates into our Infotype 0001 so that there feed doesnt overwrite our original dates. I have attempted to use HR_INFOTYPE_OPERATION with no luck. Any one have a possible way to update InfoType 0001 without using a BDC?

    What exactly is the issue? In any case HR_INFOTYPE_OPERATION in turn calls HR_MAINTAIN_MASTERDATA so you might end up with the same issue with either function call.
    ~Suresh

  • 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

  • Function to update Infotype 0003

    Hi,
    I want to update 'Run payroll up to' field of infotype 0003 based on some conditions .
    Is there any function module to update Infotype 0003 fields ?
    Thanks

    I have calle the FM with action 'EDQ'  .
    It did not uloack the pernr .
    I am using this code :
    SELECT SINGLE STAT2
      INTO LV_STAT2
      FROM  PA0000
      WHERE PERNR =  INNNN-PERNR AND
            ENDDA >= INNNN-BEGDA AND
            BEGDA <= INNNN-ENDDA .
      IF SY-SUBRC = 0 AND
        LV_STAT2 <> '3'  .
        CALL FUNCTION 'HR_READ_INFOTYPE'
          EXPORTING
            PERNR           = INNNN-PERNR
            INFTY           = '0003'
          IMPORTING
            SUBRC           = LV_SUBRC_1
          TABLES
            INFTY_TAB       = IT_PA0003
          EXCEPTIONS
            INFTY_NOT_FOUND = 1
            OTHERS          = 2.
        IF LV_SUBRC_1 = 0 .
          READ TABLE IT_PA0003 INDEX 1  .
          CHECK SY-SUBRC = 0 .
          WA_PA0003 = IT_PA0003 .
          IF INNNN-BEGDA >  IT_PA0003-ABWD1  .
         Reset the  "Run payroll for pers.no. up to" date
            WA_PA0003-ABWD1 = INNNN-BEGDA  .
            CALL FUNCTION 'HR_INFOTYPE_OPERATION'
              EXPORTING
                INFTY                  = '0003'
                NUMBER                 = INNNN-PERNR
                RECORD                 =  WA_PA0003
                OPERATION              = 'EDQ'
             IMPORTING
               RETURN                 =  LV_SUBRC_2          .
            CALL FUNCTION 'HR_INFOTYPE_OPERATION'
              EXPORTING
                INFTY                  = '0003'
                NUMBER                 = INNNN-PERNR
                VALIDITYEND            = WA_PA0003-ENDDA
                VALIDITYBEGIN          = WA_PA0003-BEGDA
                RECORD                 =  WA_PA0003
                OPERATION              = 'MOD'
                NOCOMMIT               =  'X'
             IMPORTING
               RETURN                 =  LV_SUBRC_2

  • 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.

  • Update infotype 0041 in payroll function

    Hi,
    I have created a payroll function to update infotype 0041 during payroll process, but it seems this is causing some inconsistencies in PCL2 cluster,since I'm having some payroll errors.
    Is there anyway to avoid this? Can I create an infotype during the payroll process, or this is not advisable?
    Thanks in advance.
    Best regards,
    Sónia Gonçalves

    You have to make the function call a separate unit of work.One other option is to put the function call in a report & SUBMIT it from the User exit.
    ~Suresh

Maybe you are looking for

  • Report showing Payment to vendor with PO and item details

    Hi there, Could you please let us know if in the standard system there is a report for Payment for vendor that shows PO item number along with payment details. We appreciate your reply. Thanks, Gajanan

  • Build Application Error

    I am consistently getting an Error 26071 when I try to build my application to make an .EXE.  I am usling LV6.1, and Application Builder for it.  The app. works just fine from within LV itself.  There are no errors. Specifically, the error message is

  • Zenworks Imaging

    Hello, I have a problem with our ZenWorkserver. After 2 week ServerUptime I get on the workstation in PXE-Boot following error: PXE-T04 Illegeal TFTP-Operation PXE-E36 Error received from TFTPServer. On the Server I see no Errors. I have a Netware 6.

  • Dv6 series - DPC latency spikes

    I currently have a Dell laptop with frequent DPC latency spikes. As a result, I will be returning the laptop for a new laptop that does not have those spikes. http://www.shopping.hp.com/webapp/shopping/product_detail.do?storeName=storefronts&landing=

  • IMovie- Audio Editing Problems

    Basically here is the situation. When i click on a video in my project and then click adjust audio. I do not get the adjust audio pop-up but just the skimming line over my video with a red dot in the center of the skimming line. I have tried restarti