Custom infotype updation

Hi Expects,
I am working on custom infotype creation. In my requirement I have used table control concept where user enters multiple records and updates the custom infotype.
For a single PERNR,SUBTYPE, BEGDA and ENDDA I want to update multiple records into the infotype using table control concept.
Ex: PERNR : 25
      SUBTY: 2001
      BEGDA: 01/01/2001
      ENDDA: 12/31/2001
Here by using the function modules 'HR_INFOTYPE_OPERATION' or 'HR_MAINTAIN_MASTERDATA' I am trying to update the custom infotype where sequence number need to be increamented automatically for duplicate entries but only one record is getting updated instead of multiple records.
I have maintained the time constraint as '3'.
Please let me know the procedure to update multiple records at a time into custom infotype.
Regards,
Mahesh.

Hi,
In the custom infotype table, if their are  duplicate then the sequence number field value will be created automatically for time constainst '3' but using the function module it is not creating the sequence number but using the modify statement it is working fine.
Ex: Modify PA9002 from table GT_PA9002.
Please let me know the solution for updating multiple records into a custom infotype.
Regards,
Mahesh.

Similar Messages

  • HR ABAP : Custom Infotype updations through FM HR_INFOTYPE_OPERATION

    Hi All,
              Actually, I want to update the custom infotype 3 fields as per my user inputs. I am fetching the data from the PA table acoording to sy-datum falling in the begda, enda limitations. now I am changing the field with new values in the work area. And pass with the following data to the FM.
              But I am getting the error 'No data stored for 9008 in the selected period', eventhough it is already having a data in the database table. I had seen prvious therads, but could not get how they solved the issue.
    Please provide the inpus for the following code.
              ( I had also passed the validity start and end from the database entry. at this moment it gets dumped at the statement
      assign record to <record> casting type (tabname). "XDP UniCode
    where tabname is proposed from t777d-ppnnn. which is a structure and having a value as P9008. If i change the value at debug point to PA9008. it works fine. is there anything extra i need to do to solve this issue? )
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
    EXPORTING
    infty = '9008'
    number = pernr
    "SUBTYPE =
    "OBJECTID =
    "LOCKINDICATOR =
    "VALIDITYEND =
    "VALIDITYBEGIN =
    "RECORDNUMBER =
    record = wa_pa9008
    operation = 'MOD'
    "TCLAS = 'A'
    "DIALOG_MODE = '0'
    "NOCOMMIT =
    "VIEW_IDENTIFIER =
    "SECONDARY_RECORD =
    IMPORTING
    return = l_bapireturn
    key = bapipakey_tab
    Regards,
    Brijesh Patel

    Hi,
    Check this code once
    Read Infotype9004 Record for the personnel No
        CALL FUNCTION 'HR_READ_INFOTYPE'
          EXPORTING
            tclas           = A
            pernr           = pernr
            infty           = 9004
          IMPORTING
            subrc           = v_subrc
          TABLES
            infty_tab       = it_pa9004
          EXCEPTIONS
            infty_not_found = 1
            OTHERS          = 2.
    Read it_pa9004 into wa_pa9004 with some condition.
    if sy-subrc eq 0.
    Lock the employee for processing infotype 9004
        CALL FUNCTION 'HR_EMPLOYEE_ENQUEUE'
          EXPORTING
            number = wa_pa9004-pernr.
      v_begda = wa_9004-begda.
          v_endda = wa_9004-endda.
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
            EXPORTING
              infty         = c_9004
              number        = wa_9004-pernr
              subtype       = c_0001
              validityend   = v_endda
              validitybegin = v_begda
              record        = wa_9004
              operation     = c_mod
              tclas         = c_a
             dialog_mode   = c_0
              dialog_mode   = '2'
            IMPORTING
              return        = wa_return.
    CALL FUNCTION 'HR_EMPLOYEE_DEQUEUE'
          EXPORTING
            number = wa_pa9004-pernr.
    endif.
    reward the points if it is helpful.
    Regards,
    Srilatha

  • HR ABAP : Custom Infotype updations

    Hi All,
    I am new to HR ABAP. Actually, I want to update the custom infotype 3 fields as per my user inputs. I am fetching the data from the PA table acoording to sy-datum falling in the begda, enda limitations. now I am changing the field with new values in the work area. And pass with the following data to the FM.
    But I am getting the error 'No data stored for 9008 in the selected period'. I had seen prvious therads, but could not get how they solved the issue.
    Please provide the inpus for the following code. I had also passed the validity start and end.
    CALL FUNCTION 'HR_INFOTYPE_OPERATION'
    EXPORTING
    infty = '9008'
    number = pernr
    SUBTYPE =
    OBJECTID =
    LOCKINDICATOR =
    VALIDITYEND =
    VALIDITYBEGIN =
    RECORDNUMBER =
    record = wa_pa9008
    operation = 'MOD'
    TCLAS = 'A'
    DIALOG_MODE = '0'
    NOCOMMIT =
    VIEW_IDENTIFIER =
    SECONDARY_RECORD =
    IMPORTING
    return = l_bapireturn
    key = bapipakey_tab
    Regards,
    Brijesh Patel

    Hi Remi,
            I have done the same thing. Please see the code. data is also available in the database. But the output is the error message. Please give some inputs on this.
    ***Updation of the PA9003 Infoty pe with the LTA amount and Medical Amount
        SELECT SINGLE endda
                      begda
                      FROM pa0001
                      INTO (endda, begda)
                      WHERE pernr EQ pernr
                        AND endda GE sy-datum
                        AND begda LE sy-datum.
        SELECT SINGLE *
                      FROM pa9003
                      INTO lwa_pa9003
                      WHERE pernr EQ pernr
                        AND endda >= sy-datum
                        AND begda <= sy-datum.
        wa_pa9003 = lwa_pa9003.
        wa_pa9003-zzallw = zzallw.
        wa_pa9003-zzlta = zzlta.
        wa_pa9003-zzmed = zzmed.
        ADD 1 TO wa_pa9003-seqnr.
    ***Locking the object
        CALL FUNCTION 'ENQUEUE_EPPRELE'
          EXPORTING
            pernr          = pernr
          EXCEPTIONS
            foreign_lock   = 1
            system_failure = 2
            OTHERS         = 3.
        CALL FUNCTION 'HR_INFOTYPE_OPERATION'
          EXPORTING
            infty                  = '9003'
            number                 = pernr
       subtype                = wa_pa9003-subty
       objectid               = wa_pa9003-objps
       lockindicator          = wa_pa9003-sprps
       validityend            = wa_pa9003-endda
       validitybegin          = wa_pa9003-begda
       recordnumber           = wa_pa9003-seqnr
            record                 = wa_pa9003
            operation              = 'MOD'
      TCLAS                  = 'A'
      DIALOG_MODE            = '0'
      nocommit               = space
      VIEW_IDENTIFIER        =
      SECONDARY_RECORD       =
         IMPORTING
           return                 = l_bapireturn
           key                    = bapipakey_tab
    ***Unlocking the object
        CALL FUNCTION 'DEQUEUE_EPPRELE'
          EXPORTING
            pernr = pernr.
    Regards,
    Brijesh Patel

  • Hr abap custom infotype  updatation

    hiii frnds,
        i creatred custom inotype 9910 and i enterded some data for  this infotype in pa30 when i click on the save it is noty saving in the pa9910 table...... can any one send sample code to save the data into table

    Did you read [Developing an Infotype in Personnel Administration|http://help.sap.com/printdocu/core/print46c/en/data/pdf/PAXX/PYINT_INFOTYP.pdf] (or more recent documentation) and a guide like [Steps to Customize infotypes|http://wiki.sdn.sap.com/wiki/display/ABAP/StepstoCustomize+infotypes]
    Regards,
    Raymond

  • Creating / Updating Custom Infotype Records

    Hello everbody,
    We implement alot of custom HR infotypes in our system, both PA &  HRP.
    For the past several we have been using BDC (Batch-Input) recorded functions in order to update / create the records in our infotypes.
    We're currently facing an upcoming ECC upgrade , and I would like to lead a change that will eventually lead to us using generic SAP supplied functions.
    I've researched a few functions that might do the trick:
    RH_INSERT_INFTY:
    This one is giving me an SY-SUBRC 2 error code - Insert error, I tried to select a current record and insert it as different objid but this doesnt work.
    HR_INFOTYPE_OPERATION:
    I've read of several people that recommended using this function, but it is not released by SAP and I couldnt get it to work as well.
    BAPI_HRMASTER_SAVE_REPL_MULT:
    This one seems to work for sap infotypes but I dont think it suits custom infotypes.
    What is the "official" way of doing such operations?
    thanks in advance,
    Eli.

    Hello Dilak,
    Im currently trying to insert a new infotype record of infotype HRP9226.
    First I call function RH_GET_NEXT_NUMBER to get an objid.
    then I fill an HRP9226 line.
    after this i call the function:
    call function 'RH_INSERT_INFTY'
    exporting
    FCODE = 'INSE'
    vtask = 'S'
    ORDER_FLG = 'X'
    COMMIT_FLG = 'X'
    AUTHY = ' '
    PPPAR_IMP =
    OLD_TABNR = ' '
    REPID = ' '
    FORM = ' '
    KEEP_LUPD =
    WORKF_ACTV = 'X'
    tables
    innnn = hrp9226_line
    ILFCODE =
    EXCEPTIONS
    NO_AUTHORIZATION = 1
    ERROR_DURING_INSERT = 2
    REPID_FORM_INITIAL = 3
    CORR_EXIT = 4
    BEGDA_GREATER_ENDDA = 5
    OTHERS = 6
    I'm getting an "Error_During_Insert" and Im out of options regarding what I can possibly do.

  • Create Custom Infotype and handle Modification/Updation

    Hi All,
    I need to create a custom infotype and handle few checks while creating/updating the existing one.
    I have gone through the existing threads and have figured out the creation part.
    Could anyone tell me where i need to code the checks while creating/updating.
    I tried editing the PBO/PAI of the Module pool program, but as its standard, is asking for access key. Do we need to code this in any userexit or implement BADI.
    For example,
    a) i need to check that only one instance of the infotype should be valid for an  
        employee at a time
    b) This infotype should be created for only Employees and not contingent workers.
    c) Few fields on the body section needs to be updated/modified.
    Thanks and Regards
    Manish.

    You can use the IN_UPDATE or AFTER_INPUT Methods of the BAdI HRPAD00INFTY to perform your validations.
    Arya

  • Updation problem in custom infotypes.

    HI ALL,
    I have created two custom infotypes, and the process is that one infotype updates the other infotype.
    When i open the first infotype by pa30 and then open the second and changes some value which update the first infotype table. now when i go to first info type it shows the old value. untill i exit pa30 and start again then it shows the updated values. what is the solution for this.
    Thanks.

    Hi abap sap,
      It is becasue of PAI and PBO module itterations.
    Go to the custom related program created with that infotype and insert your logic to clear the field contents.
    Reward if useful!

  • Not to Update custom infotype

    Hi Expert,
    I have one custom FM which is used to update the custom infotype but my requirement is when it get fail it should not update
    the infotype but it is updating.Befor this FM we are performing operation i. e MASSN  07,08, .
    This requirement is based on contract renewal when contract is not renewed it should not update custom infotype bue it is
    updating when contract is not renewed through the above FM.
    please give me some idea so that custom infotype should not get updated when contract is not renewed.But it is
    updating the infotype what should i put to not update the infotype when contract is not renewal.
    Below is my listed code.
        IF lv_action =  '09' OR lv_action = '07' OR lv_action = '08' AND lv_cr_renewal = ''.
        CALL FUNCTION 'ZF_HCM_ALM_ABSENCE_DATA'
            EXPORTING
              i_pernr                 = lv_pernr
              i_effective_date        = lv_date
              i_updation              = 'X'
    TABLES
      T_ABSENCE_DATA          =
          t_return                = lt_return_absence
    Regards,
    Md
    Edited by: MdAddu on Jun 26, 2011 9:33 AM
    Edited by: MdAddu on Jun 26, 2011 9:52 AM

    Hi,
    Write the code as :
    IF ( lv_action = '09'  OR lv_action = '07' OR lv_action = '08' )
      AND lv_cr_renewal = ''.     "-- contract renewed ...
    CALL FUNCTION 'ZF_HCM_ALM_ABSENCE_DATA'
    EXPORTING
    i_pernr = lv_pernr
    i_effective_date = lv_date
    i_updation = 'X'
    TABLES
    T_ABSENCE_DATA =
    t_return = lt_return_absence
    Regards,
    Srini.

  • Creating / updating Custom infotype with different screen

    Hi All,
    I have created custom infotype having different screen for different subtype(1,2).
    From Subtype 1, indotype is automatically updated as it is a standard program. But for subtype 2 i am using HR_INFOTYPE_OPERATION for updating the record which is ending with error, as employee which i am trying to update is already locked by me only through PA30. So this function module ends with Complex error. Please suggest how to update the infotype with subtype 2.
    Thanking you..
    Best regards
    Akshay

    Hi All,
    I have created custom infotype having different screen for different subtype(1,2).
    From Subtype 1, indotype is automatically updated as it is a standard program. But for subtype 2 i am using HR_INFOTYPE_OPERATION for updating the record which is ending with error, as employee which i am trying to update is already locked by me only through PA30. So this function module ends with Complex error. Please suggest how to update the infotype with subtype 2.
    Thanking you..
    Best regards
    Akshay

  • Decoupling of customer infotypes; additional update mechanism

    Hi
    I am currently working in a project, were we are trying to decouple a number of own / customer infotypes (9xxx-infotypes), according to SAP's New Infotype Framework.
    In this connection we want to use the recommendations by SAP, stated in the paper: "Business Logic Guidelines for Creating & Migrating Infotypes".
    One of the challenges we have is that in the validation methods of the check class for the indiv. infotypes, we need to update other tables (Z-tables).
    The guideline says: "additional updates for tables that lie outside the PAnnnn name range must be processed via the so-called additional update mechanism".
    Does anyone know what this "additional update mechanism" is? can anyone point me to some documentation regarding this subject??

    If you would like to contact one of the UK based BT Care Team who moderate this forum, they should be able to help you.
    They can be contacted using this link BT Care Team
    They normally respond by phone or e-mail, within three working days, however you should get an immediate confirmation, with a tracking number.
    There are some useful help pages here, for BT Broadband customers only, on my personal website.
    BT Broadband customers - help with broadband, WiFi, networking, e-mail and phones.

  • Update BDCP table custom infotype custom field

    Hi All,
    I have created  a custom infoype and added a custom field with in this infotype.
    I have clicked change document button for the dataelement.
    When i changed the value with in that infotype the entry is not updating in table BDCP.
    When i changed the value in standard infotype the value is updated in table BDCP table.
    Is it possible to update the BDCP table for custom infotype custom field.
    If yes please let me know the procedure.
    Thanks,

    Hi Tarangini,
    Check the below transactions once again:-
    BD61 - To activate the Change Pointers
    BD50 - Activate the change pointer for the message type
    BD52 - To include the fields which needs to be tracked
    BD66 - Maintain Segment field and change document field.
    Check all the above transactions once again and you could resolve the problem.
    Thanks,
    Mahesh.

  • Updating custom infotype with FM 'HR_INFOTYPE_OPERATION' dumps

    Hi All,
    While updating a custom infotype 9008 with FM 'HR_INFOTYPE_OPERATION', its giving adump.
    Except.  CX_HRPA_INVALID_PARAMETER.
    I am using DIALOG_MODE as '1'. when I enter a valid field value to that particular field ( mandatory field) on that infotype, it gives dump.
    Can you suggest something which will solve this?
    Thanks.
    Dipti.

    Hi,
    Here is the dump.
    Runtime Errors         UNCAUGHT_EXCEPTION
    Except.                CX_HRPA_INVALID_PARAMETER
    Date and Time          12.11.2008 07:23:32
    Short text
    An exception occurred that was not caught.
    What happened?
    The exception 'CX_HRPA_INVALID_PARAMETER' was raised, but it was not caught
    anywhere along
    the call hierarchy.
    Since exceptions represent error situations and this error was not
    adequately responded to, the running ABAP program
    'CL_HRPA_RESOLVE_EXCEPTION=====CP' has to be
    terminated.
    Error analysis
    An exception occurred that is explained in detail below.
    The exception, which is assigned to class 'CX_HRPA_INVALID_PARAMETER', was not
    caught in
    procedure "RESOLVE_EXCEPTION" "(FORM)", nor was it propagated by a RAISING
    clause.
    Since the caller of the procedure could not have anticipated that the
    exception would occur, the current program is terminated.
    The reason for the exception is:
    Invalid parameter EXCEPTION, value
    The occurrence of the exception is closely related to the occurrence of
    a previous exception "CX_HRPA_VIOLATED_PRECONDITION", which was raised in the
    program "CL_HRPA_MASTERDATA_FACTORY====CP",
    specifically in line 6 of the (include) program
    "CL_HRPA_MASTERDATA_FACTORY====CM004".
    The cause of the exception was:
    Precondition Violated
    Missing RAISING Clause in Interface
    Program                                 SAPFP50P
    Include                                 FP50PE10
    Row                                     2,152
    Module type                             (FORM)
    Module Name                             RESOLVE_EXCEPTION
    Trigger Location of Exception
    Program                                 CL_HRPA_RESOLVE_EXCEPTION=====CP
    Include                                 CL_HRPA_RESOLVE_EXCEPTION=====CM001
    Row                                     80
    Module type                             (METHOD)
    Module Name                             RESOLVE
    Source Code Extract
    Line
    SourceCde
    50
    message_handler = message_handler.
    51
    return.
    52
    53
    catch cx_sy_move_cast_error.
    54
    endtry.
    55
    END-OF-DEFINITION.
    56
    57
    58
    try_to resolve_missing_infty_data    cx_hrpa_missing_infty_data.
    59
    try_to resolve_missing_authorization cx_hrpa_missing_authorization.
    60
    try_to resolve_invalid_feature       cx_hrpa_invalid_feature.
    61
    try_to resolve_unexpected_message    cx_hrpa_unexpected_message.
    62
    try_to resolve_missing_personid      cx_hrpa_missing_personid.
    63
    try_to resolve_invalid_infotype_db   cx_hrpa_invalid_infotype_db.
    64
    try_to resolve_invalid_customization cx_hrpa_invalid_customization.
    65
    try_to resolve_inconsistent_database cx_hrpa_inconsistent_database.
    66
    67
    68
    Just to ensure the macro can be used nowhere else.
    69
    DEFINE try_to.
    70
    END-OF-DEFINITION.
    71
    72
    If we can not remap we would like to just re-raise the
    73
    exception like below like "RAISE EXCEPTION exception.".
    74
    Unfortunately the kernel will then forget about the
    75
    original source position.
    76
    77
    So this is the fallback strategy. Calling this method
    78
    is only allowed if the exception can be resolved. Since
    79
    this is not the case we indicate a parameter violation.
    >>>>>
    RAISE EXCEPTION TYPE cx_hrpa_invalid_parameter
    81
    EXPORTING
    82
    previous  = exception
    83
    parameter = 'EXCEPTION'.
    84
    85
    ENDMETHOD.
    Regards,
    Dipti.

  • T582A Update Custom infotype information

    Hi experts,
       I created custom infotype but the table T582A does not have my custom infotype IT9009  data.
    please let me know T582A is update manually Using maintenance view or it updates while creating infotype .
    Please send your Suggestions.
    Thanks in advance.
    Regards,
    Sivakumar.A

    hi
         Table T582A  - is used for customer settings in Administration infotypes.
    the info type that u created is  for admistration  .
    Hope this will give u lead to solve ur problem
    Cheers
    Snehi

  • Updating a customer infotype detail table (in PIQSTM) from an interface

    We have a customer infotype that has a header table (HRP....) and a detail table (HRT.....) and we have this attached to transaction PIQSTM. This works fine. However, we now have a requirement to update the infotype via an interface and we have hit a problem using the standard function modules. We have tried, for example, using FM 'HRIQ_PNNNN_MAINTAIN' but have found that whilst it updates the header ok, if any detail record exists it is always overwritten. We need to keep the existing detail records attached to the same header.
    I've debugged the way our tables are updated when saved in PIQSTM and can see that there is a lot going on with buffers. It seems that buffers are updated and then FM 'RH_BASE_UPDATE_DB_DIALOG' is called, ultimately resulting in an insert to our detail infotype table. In our interface program, obviously I would prefer not to update the table directly. I guess BDC is always an option but again, I'd prefer not to use it if possible.
    Has anyone out there done this and can offer me any advice ?
    thanks,
    Malcolm.

    Malcom,
       Try to feed old HRT record and New records(from interface) to Insert/update info-type function module.
    Thanks,
    Prabhat Singh

  • How to add fields in custom infotype and update its screens

    Hi Experts
        I want to enhance a custom infotype ( Add some new fields, and add special function on its screen). This custom infotype is created in previous release.   is there any way to add fields in infotype? and let system automatcailly modify corresponding screens to add new fields

    Go to Transaction PM01.
    2) Enter the custom Infotype number which you want to create (Should be a 4 digit number, start with 9).
    3) Select the u2018Employee Infotypeu2019 radio button.
    4) Select the u2018PS Structure Infotypeu2019.
    5) Click on Createu2026 A separate table maintenance window appearsu2026
    6) Create a PS structure with all the fields you want on the Infotype
    7) Save and Activate the PS structure
    8) Go back to the initial screen of PM01.
    9) Click on u2018Allu2019 push button. It takes a few moments.
    10) Click on u2018Technical Characteristicsu2019. Infotype list screen appears
    11) Click on u2018Changeu2019(pencil) button
    12) Select your Infotype and click on u2018Detailu2019 (magnifying glass) button
    13) Give u2018T591Au2019 as subtype table
    14) Give u2018T591Su2019 as subtype txt tab
    15) Give your subtype field as subtype field
    16) Save and come back to PM01 initial screen
    17) Click on u2018Infotype Characteristicsu2019 u2026 Infotype list screen appears
    18) Click on u2018Changeu2019 (pencil) button
    19) Click on u2018New Entriesu2019
    20) Enter your Infotype number and short text
    21) Here we have to set different Infotype Characteristics as per the requirement. (Better open another session with some standard Infotypeu2019s infotype characteristics screen and use as the reference to fill yours)
    22) Save your entries.
    23) Now the Infotype is created and ready to use.
    24) If you want to change the layout of the Infotype as per your requirementu2026
    25) In the PM01 initial screenu2026Select u2018Screenu2019 radio button and give 2000 as the screen name, then click on edit.
    26) In the next screen.. Select u2018Layout Editoru2019 and click u2018Changeu2019.
    27) Screen default layout appearsu2026here you can design/modify the screen..change the attributes of the fields..etc.
    28) Save and activate. (Donu2019t forget to u2018Activate at every level
    i think u have to select CI_INCLUDE while enhanceing the Standrad Infotype

Maybe you are looking for