cancel
Showing results for 
Search instead for 
Did you mean: 

Delimit a position using FM "RH_CUT_INFTY_1001_EXT" is not updating HRP1001.

former_member300568
Participant

Hi All,

I have a situation where i am moving a person from one position to another position and i have to create a holder A008 for his old position.

I am using the below FM. I am passing

OTYPE =S

SCLAS =P

INFTY = 1001

SOBID =00001889

OBJID =40010950

ENDDA = 99991231 BEGDA =20170605 RSIGN =A RELAT = 008.

I see that the below FM calls 'rh_cut_infty' internally. When i see the code of this FM in line 230 ,when sy-subrc eq 0 and only when the buffer is ON it does the update.

I am not able to understand this and why my data is not being updated to the table.

 LOOP AT t_p1001 ASSIGNING <wa_p1001>.
    CALL FUNCTION 'RH_CUT_INFTY_1001_EXT'
      EXPORTING
        GDATE                         = <wa_p1001>-endda
        HISTO                         = ' '
        VTASK                         = 'D'
      TABLES
        INNNN                         = t_p1001[]
*       ILFCODE                       =
     EXCEPTIONS
       ERROR_DURING_CUT              = 1
       NO_AUTHORIZATION              = 2
       GDATE_BEFORE_BEGDA            = 3
       CUT_OF_TIMCO_ONE              = 4
       RELATION_NOT_REVERSIBLE       = 5
       CORR_EXIT                     = 6
       OTHERS                        = 7.
    IF SY-SUBRC <> 0.
* Implement suitable error handling here
    ENDIF.
Endloop.

Accepted Solutions (1)

Accepted Solutions (1)

former_member226519
Active Contributor
0 Kudos

try fm RH_CUT_INFTY.

Dont forget to enqueue both relations A and B (fm RH_PM_ENQUEUE)

former_member300568
Participant
0 Kudos

But 'RH_CUT_INFTY_1001_EXT internally calls FM 'RH_CUT_INFTY' right?

I am sending only A008 in my FM, should i send B 008 too?

Thanks?

Divya

former_member300568
Participant
0 Kudos

I am sending both A 008 and B 008 together with right parameters , I dont see any missing authorization for the background job, checked via st05 trace.

Not sure why i am not able to see any updates.

Answers (3)

Answers (3)

devendra_patel
Participant
0 Kudos

What all parameters are required to update the ENDDA. Code snippet will be helpful.

devendra_patel
Participant
0 Kudos
CALL FUNCTION 'RH_CUT_OBJECT'
  EXPORTING
*   LOAD               = 'X'
    gdate              = lv_date
    histo              = 'X'
    gstat              = '1'
*   INVERT             = 'X'
    vtask              = 'B'
*   ORDER_FLG          = 'X'
*   COMMIT_FLG         = 'X'
*   AUTHY              = 'X'
*   PPPAR_IMP          =
*   CUT_DEPENDENTS     = 'X'
*   KEEP_LUPD          =
*   WORKF_ACTV         = 'X'
  TABLES
    i1000              = wt_output
*   ILFCODE            =
  EXCEPTIONS
    error_during_cut   = 1
    no_authorization   = 2
    gdate_before_begda = 3
    corr_exit          = 4
    OTHERS             = 5.


IF sy-subrc = 0.


  CALL FUNCTION 'RH_UPDATE_DATABASE'
    EXPORTING
      vtask        = 'D'
      buffer_upd   = 'X'
*     ORDER_FLG    = 'X'
*     COMMIT_FLG   = 'X'
*     CLEAR_BUFFER = 'X'
*     KEEP_LUPD    =
*     WORKF_ACTV   = 'X'
    EXCEPTIONS
      corr_exit    = 1
      OTHERS       = 2.

former_member300568
Participant
0 Kudos

Thanks Sathya and Volker.

So far i have been sending only relationship A 008 inthe FM, i sent both B008 and A 008 and worked as expected.

sathyags
Active Participant
0 Kudos

Hi Divya,

Can you try vtask = 'B' and see whether that solves the issue?

*B=Buffer

Thanks

Sathya

former_member300568
Participant
0 Kudos

Hi Sahthya , I tried Vtask B that didnt work either.

I also tried A 008 and B 008 sending together to the FM

'RH_CUT_INFTY_1001_EXT' , it doesn throw any error , but i cannot see the data being updated.

Not sure where i am going wrong. Any ideas?

sathyags
Active Participant
0 Kudos

GDATE should be the delimit_date. ( If you want the new relationship should be effective from today, pass yesterday's date to GDATE). from the code snippet, I think you are passing the endda of the existing record (99991231) which is causing the problem.

Sathya