RH_UPDATE_DATABASE

Hi Guys,
I am using FM RH_INSERT_INFTY with Vtask = 'B'.
This way I process all the records and they are updated in an internal buffer.
After processing all the records I call RH_UPDATE_DATABASE to commit to database.
My question is that if I am running my program in test mode and I don't call RH_UPDATE_DATABASE, how do I clear the internal buffer that is updated by RH_INSERT_INFTY?
I would appreciate your suggestions.

You have to use these two FM together i guess:
1-'RH_CLEAR_BUFFER'.
2- 'RH_CLEAR_PLOG_TAB'.
Check this link for more details:
BAPI_HRMASTER_SAVE_REPL_MULT
Regards
Neha

Similar Messages

  • VTASK problem in RH_UPDATE_DATABASE

    Hi Experts,
    I'm using RH_OBJECT_CREATE to create new position and RH_RELATION_WRITE to create relation of position to Org.Unit and using RH_UPDATE_DATABASE after both...but using VTASK as 'S'.
    This is not showing any exception but sends a SAP Mail as 'Update was terminated '...same happens if i use VTASK as 'V'.
    It creates all object if I use VTASK as 'B' but doesnt update in database, 'D' updates the database, but I want to trigger this process in Background..
    Please Help..Please check my below code if I'm wrong somewhere. Thanks
      CALL FUNCTION 'RH_OBJECT_CREATE'
        EXPORTING
         LANGU                      = SY-LANGU
          PLVAR                     = '01'
          OTYPE                     = 'S'
      EXT_NUMBER                = '00000000'
          SHORT                     =  SHORT
          STEXT                     =  STEXT
          BEGDA                     =  BEGDA
          ENDDA                     =  '99991231'
      OSTAT                     = '1'
          VTASK                     = 'B'
      GUID                      =
      KEEP_LUPD                 = ' '
       IMPORTING
         OBJID                     = OBJID
       EXCEPTIONS
         TEXT_REQUIRED             = 1
         INVALID_OTYPE             = 2
         INVALID_DATE              = 3
         ERROR_DURING_INSERT       = 4
         ERROR_EXT_NUMBER          = 5
         UNDEFINED                 = 6
         OTHERS                    = 7
      RELATION-MANDT = SY-MANDT.
      RELATION-PLVAR = '01'.
      RELATION-BEGDA =  BEGDA.
      RELATION-ENDDA =  '99991231'.
      RELATION-INFTY = '1001'.
      RELATION-ISTAT = '1'.
      RELATION-RELAT = '003'.
      RELATION-RSIGN = 'A'.
      RELATION-OTYPE = 'S'.
      RELATION-OBJID =  OBJID.
      RELATION-SCLAS = 'O'.
      RELATION-SOBID =  SOBID.
      RELATION-VARYF(2) = 'O '.
      RELATION-VARYF+2(8) = SOBID.
      APPEND RELATION.
      CALL FUNCTION 'RH_RELATION_WRITE'
        EXPORTING
          VTASK                = 'B'
        TABLES
          RELATION             = RELATION
        EXCEPTIONS
          NO_AUTHORITY         = 1
          RELATION_NOT_ALLOWED = 2
          OBJECT_NOT_FOUND     = 3
          WRONG_DATE_FORMAT    = 4
          TIME_NOT_VALID       = 5
          ERROR_DURING_INSERT  = 6
          UNDEFINED            = 7
          OTHERS               = 8.

    Hi
    am facing problem in RH_OBJECT_CREATE for creating Org.units
    code is like,
    data :  wa_id like hrp1000-objid,
             begin of imat occurs 100,
             plvar like PPHDR-PLVAR,
             otype like PPHDR-OTYPE,
             begda  like PPHDR-BEGDA,
             endda like PPHDR-ENDDA,
             SHORT like P1000-SHORT,
             stext   like  P1000-STEXT,
             seark   like  PM0D1-SEARK,
             end of imat,
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      = 'C:/ABC.TXT'
      FILETYPE                      = 'ASC'
       HAS_FIELD_SEPARATOR           = 'X'
    IMPORTING
      FILELENGTH                    =
      HEADER                        =
      TABLES
        DATA_TAB                      = imat
    loop at imat into wa.
    CALL FUNCTION 'RH_OBJECT_CREATE'
      EXPORTING
       LANGU                     = SY-LANGU
        PLVAR                     = '01'
        OTYPE                     = 'O'
      EXT_NUMBER                = '00000000'
       SHORT                     = wa-short
        STEXT                     = wa-stext
       BEGDA                     = wa-begda
       ENDDA                     =  wa-endda
       OSTAT                     = '1'
       VTASK                     = 'S'
      GUID                      =
      KEEP_LUPD                 = ' '
    IMPORTING
       OBJID                     = wa_id
    EXCEPTIONS
       TEXT_REQUIRED             = 1
       INVALID_OTYPE             = 2
       INVALID_DATE              = 3
       ERROR_DURING_INSERT       = 4
       ERROR_EXT_NUMBER          = 5
       UNDEFINED                 = 6
       OTHERS                    = 7
    IF SY-SUBRC EQ 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    write :/ wa_id.
    ENDIF.
    endloop.
    still org units are not creating pls help me to know where am mistaking..
    Regards
    Meeta

  • Issue while updating vacancy details through 'RH_UPDATE_DATABASE'

    Hi,
    i am trying to update the vacancy details through a Zprogram.
    This zprogram updates the infotype 1007 correctly which is done by:
    CALL FUNCTION 'RH_INSERT_INFTY'
        EXPORTING
          fcode               = 'INSE'
          vtask               = 'B'
        TABLES
          innnn               = lt_1007   " lt_1007 has all the values for updation.
    After this i am calling the fm :
      CALL FUNCTION 'RH_UPDATE_DATABASE'
          EXPORTING
            vtask     = 'S'
          EXCEPTIONS
            corr_exit = 1
    This updates the infotype 1007 in the database but the vacancy table T750X is not updated.
    However if i run the zprogram in foreground, this FM 'RH_UPDATE_DATABASE' updates infotype 1007 and also the table T750X. But in background mode only infotype 1007 is being updated and not T750X.
    Please let me know if any idea on how to solve this.
    Thanks.

    any inputs on this if any one had the same issue using 'RH_UPDATE_DATABASE'.

  • RH_UPDATE_DATABASE issue: how to close prompted  information

    hi
    i use RH_UPDATE_DATABASE to update HR OM mass position  data! but will get message when some error or information occur.
      CALL FUNCTION 'RH_UPDATE_DATABASE'
        EXPORTING
         VTASK     = 'D'
           VTASK     = 'S'
        EXCEPTIONS
          CORR_EXIT = 1
          OTHERS    = 2.
    how to close message prompted! when program running!
    thank you very much!
    waiting online!!!

    try passing the value of VTASK as 'B' . this should work .
    Thanks,
    Aditya. V

  • Error while saving the budget in ECM

    Hi,
    I am implementing ECM. I am getting an error everytime i try to save the Budget created in MSS.
    The error details are :
    The following error text was processed in the system XXX : Error sending data, session terminated
    The error occurred on the application server zzzz_XXX_00 and in the work process 0 .
    The termination type was: TH_RES_FREE
    The ABAP call stack was:
    Module: %_CTL_OUTPUT_FLUSH of program SAPMSSYD
    Function: TRINT_ORDER_CHOICE of program SAPLSTRD
    Function: TR_EDIT_CHECK_OBJECTS_KEYS of program SAPLSTRD
    Function: TR_OBJECTS_INSERT of program SAPLSTRD
    Function: RH_HRPOBJECT_CORR_AT_SAVE of program SAPLRHWM
    Form: UPDATE_PLOG of program SAPLRHAP
    Function: RH_UPDATE_DATABASE of program SAPLRHAP
    Function: HRCM_BTDB_UPDATE_DB of program SAPLRHBV
    Function: HR_ECM_SAVE_BUDGET_CHANGES of program SAPLHRECM00BUDGETSTRUC
    Form: DO_SAVE of program CL_HRECM00_BSP_RESULT_BUDGET==CP
    Can anyone help me resolving this.
    Regards,
    Neha

    Hi Nishu,
    ask your xi basis guys to see the disk space of your xi system.........i think the log files of your xi system have consumed too much space on your xi system.... ask your basis guys to make some space available in your xi system then your this problem will be resolved.......
    Thanks,
    Rajeev Gupta

  • ECM- Budget Creation, Error type: TH_RES_FREE

    Hi,
    I am trying to create a budget in ECM. When trying to Save the created budget i am getting the followin error.
    The following error text was processed in the system XXX : Error sending data, session terminated
    The termination type was: TH_RES_FREE
    The ABAP call stack was:
    Module: %_CTL_OUTPUT_FLUSH of program SAPMSSYD
    Function: TRINT_ORDER_CHOICE of program SAPLSTRD
    Function: TR_EDIT_CHECK_OBJECTS_KEYS of program SAPLSTRD
    Function: TR_OBJECTS_INSERT of program SAPLSTRD
    Function: RH_HRPOBJECT_CORR_AT_SAVE of program SAPLRHWM
    Please help.
    Regards,
    Neha
    Form: UPDATE_PLOG of program SAPLRHAP
    Function: RH_UPDATE_DATABASE of program SAPLRHAP
    Function: HRCM_BTDB_UPDATE_DB of program SAPLRHBV
    Function: HR_ECM_BUILD_BUDGET_STRUC of program SAPLHRECM00BUDGETSTRUC
    Function: HR_ECM_CLONE_BUDGET_FROM_ORG of program SAPLHRECM00BUDGETSTRUC

    Hi Amol,
    First of all the sicf transaction is to be used only if you use the internal ITS.
    Now you have to put an external breakpoint in the source code of the ABAP Program or FM you want to debug , one of these in your case :
    Function: B40B_READ_TABLE of program SAPLBBP_BD_DRIVER_40B
    Function: META_READ_TABLE of program SAPLBBP_BD_META_BAPIS
    Form: LOCATIONS_READ of program SAPLBBP_ATTR_F4
    Function: BBP_ATTR_F4_SLOC_PPOMA of program SAPLBBP_ATTR_F4
    Form: STG_LOC_GET_FOR_LOCATION of program SAPLBBP_SC_APP
    Form: STG_LOC_GET of program SAPLBBP_SC_APP
    Form: LOCATION_STG_LOC_GET of program SAPLBBP_SC_APP
    Form: USER_ATTRIBUTES_GET of program SAPLBBP_SC_APP
    Then launch the transaction in IE, once the program reaches a breakpoint, you'll get the ABAP debuger in IE.
    Regards.
    PS: if it doesn't work, put the parameter ~generatedynpro in BBPGLOBAL service to have it applied to all BBP transactions
    Vadim

  • RunTime error DBIF_RSQL_INVALID_RSQL while updating infotype 0035

    Dear Experts,
    I am delimiting(changing the end date from future date to current date) the HR objects in IT 0035 using FM RH_CUT_INFTY. It is delimiting the records as per required.
    To do this update we have developed a report where we read the Object ID and the PERNR on the selection screen and inside the program we update IT35.
    The program executes in three steps:
    1. Lock HR Object
    2. Update(in synchronous mode) the records for the specified Object ID-PERNR pair using FM RH_CUT_INFTY
    3. Release HR object and go to next HR object and go back to step 1.
    The report is executing good when there are less number of records for an HR object. But, when the number of (PERNR)records for an HR object is more then the report is giving a po-up "Update was terminated" and when I checked the dump for the same in ST22, it gives the following details:
    Runtime Errors : DBIF_RSQL_INVALID_RSQL
    Exception         : CX_SY_OPEN_SQL_DB
    I would be grateful if anyone can please help me resolve this issue.
    Thanks,
    Jiten

    Hi Jiten,
    I don't know how much I can help you on this.
    But I found an FM: RH_CUT_INFTY_GENERIC
    This FM seems to be designed for mess process of CUT INFTY.
    I check the source code, the VTASK is set to 'B' when calling RH_CUT_INFTY in a loop.
        CALL FUNCTION 'RH_CUT_INFTY'
             EXPORTING
                  LOAD               = ' '
                  GDATE              = GDATE
                  HISTO              = HISTO
                  DEL_SUCC           = DEL_SUCC
                  VTASK              = 'B'
                  ORDER_FLG          = ORDER_FLG
                  COMMIT_FLG         = COMMIT_FLG
                  AUTHY              = AUTHY
              PPPAR_IMP          =
                  KEEP_LUPD          = KEEP_LUPD
                  WORKF_ACTV         = WORKF_ACTV
             TABLES
                  INNNN              = action_tab
               ILFCODE            =
             EXCEPTIONS
                  ERROR_DURING_CUT   = 1
                  NO_AUTHORIZATION   = 2
                  GDATE_BEFORE_BEGDA = 3
                  CUT_OF_TIMCO_ONE   = 4
                  CORR_EXIT          = 5
                  OTHERS             = 6.
    And when all the objects have been submitted to delimitation, call FM RH_UPDATE_DATABASE at last.
    I think this could be a workaround for your issue.
    Cheers,

  • Screen output without connection to user - Goals Standard APP

    Hi Experts,
    We have configured Standard PA iview - GOALS (web dynpro application HAP_A_PMP_GOALS) into Quality Portal.  When creating new goal and clicking on save button we are getting following dump. But the same is working in development server which is not working in quality.
    Only difference between these two servers is, SSO certificate is configured in Dev but no in Quality. But I guess this should be an issue since in both the servers I am using user mapping (not logonticket).
    The following error text was processed in the system DRC : Screen output without connection to user.
    The error occurred on the application server drcr3cs2_DRC_00 and in the work process 0 .
    The termination type was: RABAX_STATE
    The ABAP call stack was:
    Function: TRINT_ORDER_CHOICE of program SAPLSTRD
    Function: TRINT_OBJECTS_CHECK_AND_INSERT of program SAPLSTRD
    Function: TR_EDIT_CHECK_OBJECTS_KEYS of program SAPLSTRD
    Function: SCPR_SWITCH_OBJECTS_INSERT of program SAPLSCPRCRITICAL
    Function: TRINT_OBJECTS_CHECK_AND_INSERT of program SAPLSTRD
    Function: TR_OBJECTS_INSERT of program SAPLSTRD
    Function: RH_HRPOBJECT_CORR_AT_SAVE of program SAPLRHWM
    Form: UPDATE_PLOG of program SAPLRHAP
    Function: RH_UPDATE_DATABASE of program SAPLRHAP
    Function: HRHAP_C_VJ_CREATE of program SAPLHRHAP_C_IF_CASCADING_GOALS
    any one knows what could be the issue, any particular service need to be activated in Backend
    Thanks
    Murthy

    Hi Chinna Babu,
    Could you please elaborate your answer ? which back end configuration was missing ?
    Regards,
    Bindumadhav Ambike

  • Test creation of hr master data/objects

    Hello,
    in my programm i need to create some objects(training events, groups, types, locations,..)/infotypes. I would like to offer to enduser some "testing/simulation" behaviour - the infotypes will not be stored in database at the end of processing. So i wanted to use parameter vtask = 'B' - buffer of FMs RH_OBJECT_CREATE and RH_INSERT_INFTY and at the finish of procces call FM RH_UPDATE_DATABASE in case that the user wants to store information, in other case call this fm with parameter CLEAR_BUFFER       = 'X' to clear this buffer. But when i was making some test the bufer was not cleared and the objects were created after calling this fm at next runs of programm.
    So my question is: how should i clear the buffer?
    Thanks,
    JJ

    The following function calls might help..
    RH_CLEAR_BUFFER  
    RH_DELETE_BUFFER 
    RH_PM_INFTY_BUFFER_REFRESH    
    ~Suresh

  • Customer creation with Business Partner Error

    Hello Experts,
    I am a Functional consultant and trying to create Customer which has to create a Business Partner in one of the test system. All the config to create Business Partner is completed.
    When trying to create customer it throws a RFC connection error. I have pasted the dump details below. Please help me to solve the issue.
    Category          
    ABAP Programming Error
    Runtime Errors    
    CALL_FUNCTION_OPEN_ERROR
    ABAP Program      
    CL_RPM_FES_BUFFER_MANAGEMENT==CP
    Application Component  PPM-PFM
    Date and Time     
    22.09.2014 19:43:45
    Short text
        Error when opening an RFC connection ("CPIC-CALL: 'ThSAPOCMINIT' : cmRc=20
    What happened?
        Error in the ABAP Application Program
        The current ABAP program "CL_RPM_FES_BUFFER_MANAGEMENT==CP" had to be
         terminated because it has
        come across a statement that unfortunately cannot be executed.
    Error analysis
        An error occurred when executing a Remote Function Call.
        "CPIC-CALL: 'ThSAPOCMINIT' : cmRc=20 thRc=236#SAP gateway connection failed. Is
         SAP gateway started? "
        Status of connection.... "CODE=CM_PRODUCT_SPECIFIC_ERROR -1 -1 SAPCODE=236
         CONV= "
        Internal error code.... "RFC_IO5"
        There is an error in the communication system. To clarify
    and resolve the error, contact your system administrator.
    Last error logged in SAP kernel
    Component............ "NI (network interface)"
    Place................ "SAP-Gateway on host KNACKS06 / sapgw01"
    Version.............. 40
    Error code........... "-10"
    Error text........... "partner 'knacks06:sapgw01' not reached"
    Description.......... "NiPConnect2: 54.201.94.167:3301"
    System call.......... "connect"
    Module............... "nixxi.cpp"
    Line................. 3286
    The error reported by the operating system is:
    Error number..... 10060
    Error text....... "WSAETIMEDOUT: Connection timed out"
    Check the host name and service that define the remote program. Are
    these parameters correct? You can use the "ping" command to check
    whether the specified host is reachable. If the remote program is an
    application server, check whether it is running and whether the local
    gateway of this server is listening for the specified service. If the
    service is sapgw<nn>, the remote server must run with SAPSYSTEM number
    <nn>.
    Trigger Location of Runtime Error
        Program                                 CL_RPM_FES_BUFFER_MANAGEMENT==CP
        Include                                 CL_RPM_FES_BUFFER_MANAGEMENT==CM00J
        Row                                     2
        Module type                             (METHOD)
        Module Name                             CHANGES_BY_ORG
    Source Code Extract
    Line  SourceCde
        1 METHOD changes_by_org.
    >>>>>   CALL FUNCTION 'RPM_FES_RECALCULATE_BY_ORG' STARTING NEW TASK 'RPM_FES_RECALCULATE_BY_ORG'
        3     EXPORTING
        4       old_image         = old_image
        5       new_image         = new_image
        6       plog_tab          = plog_tab
        7       tb_plog_tab       = tb_plog_tab
        8 *   IMPORTING
        9 *     ET_MSG            =
       10 *     EV_RC             =
       11             .
      12
      13 ENDMETHOD.
    Active Calls/Events
    No.   Ty.          Program                             Include                             Line
          Name
       13 METHOD       CL_RPM_FES_BUFFER_MANAGEMENT==CP    CL_RPM_FES_BUFFER_MANAGEMENT==CM00J     2
          CL_RPM_FES_BUFFER_MANAGEMENT=>CHANGES_BY_ORG
       12 METHOD       CL_IM_RPM_FES_ORG_CHANGES=====CP    CL_IM_RPM_FES_ORG_CHANGES=====CM004     4
          CL_IM_RPM_FES_ORG_CHANGES=>IF_EX_HRBAS00INFTY~IN_UPDATE
       11 METHOD       CL_EX_HRBAS00INFTY============CP    CL_EX_HRBAS00INFTY============CM004    35
          CL_EX_HRBAS00INFTY=>IF_EX_HRBAS00INFTY~IN_UPDATE
       10 FORM         SAPLRHAP                            LRHAPF1R                              110
          UPDATE_DATABASE
        9 FUNCTION     SAPLRHAP                            LRHAPU08                               19
          RH_BASE_UPDATE_DB_DIALOG
        8 FORM         SAPLRHAP                            LRHAPF30                              248
          UPDATE_PLOG
        7 FUNCTION     SAPLRHAP                            LRHAPU40                               31
          RH_UPDATE_DATABASE
        6 FORM         SAPLBUBA_4                          LBUBA_4F31                             14
          HR_DATA_SAVE
        5 FORM         SAPMSSY0                            SAPMSSY0                              504
          %_PROCESS_P_O_C
        4 FORM         SAPMSSY0                            SAPMSSY0                              249
          %_COMMIT
        3 FORM         SAPMF02D                            MF02DFS0                              511
    SCHLUSS_BEARBEITUNG
    2 FORM    
    SAPMF02D                       
    MF02DFO0                        
    2335
    OKCODE_BEARBEITEN
    1 MODULE (PAI) SAPMF02D                       
    MF02DI00                        
    5632
    OKCODE_BEARBEITEN
    Regards,
    BV PATIL

    Hi,
    It would make more sense to speak to a technical resource who is familiar with your system.  Based on the error, it looks like you have connection issues in your landscape - I'm assuming you have CRM & ERP systems communicating and it looks like there is a problem with their connectivity. Best get some basis resource to help you out.
    cheers,
    G.

  • Maintaining it1007 programmatically

    I need to develop a program that takes in two position numbers and delimits the vacancy record for the first position and creates a vacancy record for the second position. I am trying to use the SAP standard functions RH_CUT_INFTY and RH_INSERT_INFTY respectively but I seem to keep getting errors when the functions try to run. Is there some reason I can't get these classes to work for it1007.
    Here is the main parts of the code that I have tried:
      CALL FUNCTION 'RH_READ_INFTY'
        EXPORTING
          plvar                = '01'
          otype                = c_plans
          objid                = plans_filled
          infty                = c_1007
          begda                = effective_date
          endda                = effective_date
        TABLES
          innnn                = l_p1007_old
        EXCEPTIONS
          all_infty_with_subty = 1
          nothing_found        = 2
          no_objects           = 3
          wrong_condition      = 4
          wrong_parameters     = 5
          OTHERS               = 6.
    *Delimit 1007 table:
      CALL FUNCTION 'RH_CUT_INFTY'
        EXPORTING
          gdate              = effective_date
          histo              = ' '
          vtask              = 'B'
        TABLES
          innnn              = l_p1007_old
        EXCEPTIONS
          error_during_cut   = 1
          no_authorization   = 2
          gdate_before_begda = 3
          cut_of_timco_one   = 4
          corr_exit          = 5
          OTHERS             = 6.
    *Create Vacancy
      ls_p1007-vacan  = 'X'.
      ls_p1007-begda  = effective_date.
      ls_p1007-status = '0'.
      ls_p1007-objid  = plans_vacan.
      ls_p1007-otype  = c_plans.
      ls_p1007-plvar  = '01'.
      ls_p1007-istat  = '1'.
      ls_p1007-endda  = '99991231'.
      ls_p1007-infty  = '1007'.
      APPEND ls_p1007 TO l_p1007_new.
    **Insert new record
      CALL FUNCTION 'RH_INSERT_INFTY'
        EXPORTING
          fcode               = 'INSE'
          vtask               = 'B'
        TABLES
          innnn               = l_p1007_new
        EXCEPTIONS
          no_authorization    = 1
          error_during_insert = 2
          repid_form_initial  = 3
          corr_exit           = 4
          begda_greater_endda = 5
          OTHERS              = 6.

    Look at OSS [Note 648608 - Infotype 1007: Function INSE not allowed|https://service.sap.com/sap/support/notes/648608]
    Also, you use VTASK = 'B', Changes are buffered, so you have to call function module RH_UPDATE_DATABASE. (Look at function module documentation)
    Regards

  • Function Module RH_UPDATE_INFTY throwing odd error

    I am trying to update a relationship using this FM, however I keep getting the error "No input help is available" which I assume is a false-negative.
    I have traced the code through and the error is being thrown here:
        PERFORM RE777Z_RA(MSTT777Z) USING                      "VWMZB3A
                PPLOG-OTYPE PPLOG-INFTY PPLOG-SUBTY PPLOG-VDATA(2)
                PPPAR-TIMCO PPPAR-ADDCO PPPAR-SCLAS SUBRC.
        IF SUBRC GT 0.
          UI_SUBRC = 16.
          EXIT.
        ENDIF.
    UI_SUBRC is getting set to 16, and it is failing. I have been trying for hours to get this and other related FMs to work correctly without luck. I managed to get RH_INSERT_INFTY to work, however it is not really acting as I want it to; hence this FM. The insert FM splits the records if you make an update to enda/begda which is undesirable. This thread details the problem and ther was no posted solution overwriting records in hrp1000
    Here is what I have:
      DATA ls_p1001 TYPE p1001.
      DATA lt_p1001 TYPE STANDARD TABLE OF p1001.
      DATA ls_padd2 TYPE padd2.
      MOVE-CORRESPONDING is_dlgt_rprt TO ls_p1001.
      APPEND ls_p1001 TO lt_p1001.
      CALL FUNCTION 'RH_UPDATE_INFTY'
        EXPORTING
          vtask               = 'S'
    *     order_flg           = 'X'
    *     commit_flg          = 'X'
    *     authy               = 'X'
    *     pppar_imp           = ''
    *     old_tabnr_new_langu = 'X'
    *     repid               = sy-cprog
    *     form                = ''
    *     keep_lupd           = ''
    *     workf_actv          = 'X'
        TABLES
          innnn               = lt_p1001
    *     ILFCODE             = ILFCODE
        EXCEPTIONS
          error_during_update = 1
          no_authorization    = 2
          repid_form_initial  = 3
          corr_exit           = 4
          OTHERS              = 5.

    Hi,
    Please find documentation below:
    FU RH_UPDATE_INFTY
    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.
    The values of the parameter VTASK (update type) mean the following:
    - 'D' -> update in dialog
    - 'S' -> synchronous update via the update task
    - 'V' -> asynchronous update via the update task
    - 'B' -> internal update in buffer only, no DB update
    In HR applications the parameter should be set to 'D' for update in dialog. If there are multiple operations that logically belong together to be updated internally in the buffer first and then saved together to the database, you should set the parameter in each case to 'B' for internal update in buffer only, no DB update. The DB update is then executed by calling the function module 'RH_UPDATE_DATABASE'.
    Parameters
    VTASK
    ORDER_FLG
    COMMIT_FLG
    AUTHY
    PPPAR_IMP
    OLD_TABNR_NEW_LANGU
    REPID
    FORM
    KEEP_LUPD
    WORKF_ACTV
    INNNN
    ILFCODE
    Exceptions
    ERROR_DURING_UPDATE
    NO_AUTHORIZATION
    REPID_FORM_INITIAL
    CORR_EXIT
    Thanks,
    Sriram Ponna.

  • OM technnical quieries

    HI,
    Can any body have technical document for OM........
    as an abap-hr programming like FM,macros,
    etc............
    send it to me.......

    Hi Vinay,
    The below info would be helpful to u. You can refer HR350 as well chapter 8.
    SAP Functions Module to find the manager of org unit position personnel no or user.
    RH_GET_LEADING_POSITION and RH_GET_PERSONS_FROM_POSITION
    HRCM_ORGUNIT_MANAGER_GET
    RHPH_STRUCTURE_READ, RH_STRUC_GET find all the employee under an org. unit
    Read OM infotype
    RH_READ_INFTY
    RH_READ_OBJECT
    Maintain OM Infotype:
    RH_PM_ENQUEUE
    RH_PM_DEQUEUE
    RH_PNNNN_MAINTAIN/RH_UPDATE_INFTY
    Maintain/Delimit Relationship for OM infotypes
    RH_CUT_INFTY
    Delimit OM Objects:
    RH_CUT_OBJECT
    Update database for OM objects operation in background
    RH_UPDATE_DATABASE
    Determine whether a position is vacant:
    RH_GET_VACANCY
    Br/Manas

  • Unable to create org unit using RH_INSERT_INFTY

    All,
    We are using internal number range to create Org Units in the SAP System. However, there are some org objects present in a legacy SAP system that we need to upload to the new ECC system and create relationships for them .
    Following is my code for the RH_INSERT_INFTY function module :
    w1000-mandt = sy-mandt.
    w1000-plvar = '01'.
    w1000-otype = 'O'.
    w1000-OBJID = ''.
    w1000-infty = '1000'.
    w1000-ISTAT = '1'.
    w1000-begda = '20090101'.
    w1000-endda = '99991231'.
    w1000-langu = 'E'.
    w1000-short = 'HR_AST5'.
    w1000-stext = 'HR Assistant 5'.
    append w1000 to i1000.
    CALL FUNCTION 'RH_INSERT_INFTY'
      EXPORTING
       FCODE                     = 'INSE'
        VTASK                     = 'S'
       ORDER_FLG                 = 'X'
       COMMIT_FLG                = 'X'
      TABLES
        INNNN                     = i1000
    IF SY-SUBRC <> 0.
    ENDIF.
    I am however unable to create the org units as i get an error saying "Creation of object ID 00000000 is not allowed".
    I know im getting this error because im leaving the objid field blank, but I figured since  it is internal number range, i would have to give this as blank .
    Could somebody please help me figure out how to load these Organizational Objects and their Relationships ?
    Thanks,
    Amit

    Hi Amit
    try to use 'D' as a value of VTASK
    or use FM
    call function 'RH_OBJECT_CREATE'
        exporting
          langu                     = l_langu
          plvar                     = plvar
          otype                     = c_otype
        EXT_NUMBER                = '00000000'              "???
        SHORT                     = ' '
          stext                     = stext
          begda                     = begda
          endda                     = endda
          ostat                     = l_istat
          vtask                     = 'B'
        GUID                      =
        KEEP_LUPD                 = ' '
       importing
          objid                     = objid
       exceptions
          text_required             = 1
          invalid_otype             = 2
          invalid_date              = 3
          error_during_insert       = 4
          error_ext_number          = 5
          undefined                 = 6
          others                    = 7.
    In this FM u dont need to pass the Object ID and call function
    *---if the above steps are succesful update the database
      call function 'RH_UPDATE_DATABASE'
        exporting
          vtask              = vtask
      BUFFER_UPD         = ' '
      ORDER_FLG          = 'X'
      COMMIT_FLG         = 'X'
      CLEAR_BUFFER       = 'X'
      KEEP_LUPD          =
      WORKF_ACTV         = 'X'
       exceptions
         corr_exit          = 1
         others             = 2  .
    as VTASK 'B' will create the entry in buffer and it will only commit to database after the secondFM
    or u can try with 'D' as VTASK
    Hope this will resolve ur issue
    Regards
    Guds

  • Organization Unit and assignment plan

    Hi Experts,
    I am using function module RH_OBJECT_CREATE to create Organization Unit and now I want to do assignment plan for the created Org units.
    I am using function module RH_RELATION_WRITE for the assigment plan. But could not able to do the assignment.
    Can some one please let me know what other function module I can use to do the assignment plan?
    Thanks and Regards
    Dhananjay, TCS

    Hi
    You can try by calling the function Fodule
    'RH_UPDATE_DATABASE' immediately after RH_OBJECT_CREATE and RH_RELATION_MAINTAIN.
    Reward points if helpful
    Regards
    Manohar

Maybe you are looking for

  • HD not detected

    I inherited a decapitated iBook G4 - 14 inch early 2004 (A1095) It had been dropped twice and was received in pieces after the hard drive was removed. I purchased a HD and new ribbon cable which I installed using the instructions from iFixit.com. The

  • How do I get CC to include updates for Lightroom

    I purchased an update to LR5 before it was added to Creative Cloud. How do I get my updater tool in Creative Cloud desktop to include Lightroom automatically. Wilson

  • Basic Intel iMac with 802.11n - no mobile devices or broadband. What do I need in Australia. mrcos

                                   Saturday 7 January 2012 I am writing to ask for some advice regarding the best course of action to take with regard to my current computer situated in Sydney Australia. I have been a Netspace customer for many years wit

  • Regarding Proxies

    Hi 2 all, For making an ABAP Client Proxy we need to make an entry in Exchange Profile which helps in getting the information from Integration Builder for generating interfaces..... Now my doubt is if i am using 5-6 systems for generating interfaces.

  • JFileChooser - No Disk In Drive Error

    heres the code I have used for three other applications. For some reason the current project I am working on, no matter what button I attach the below to, seems to display a "No disk in Drive. Please insert a disk into drive A" error. The fact that t