Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

DOubt ABAP HCM infotype 2001.

ronaldo_aparecido
Contributor
0 Kudos

Hi Gurus.

I'm started a process in SAP portal to change pernr in infotype 2001 ,but it don´t worked (but is showed message ok ).

In my rfc is called the 'HR_INFOTYPE_OPERATION' .

I need understand ,why don´t worked.

maybe could have any MP... program with wrong logic?

what the programs MP to infotype 2001?

You have any suggest for solution this case? thanks.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

if changing of PERNR in an existing infotype record is what you want to do, then first of all stop wanting to do that (why would anybody ever want that?).

You always can delete the record and insert another record with the correct PERNR

11 REPLIES 11

Former Member
0 Kudos

if changing of PERNR in an existing infotype record is what you want to do, then first of all stop wanting to do that (why would anybody ever want that?).

You always can delete the record and insert another record with the correct PERNR

0 Kudos

i need change the job of line and he uses that infotype in sap and don´t change the pernr number.

0 Kudos

Thanks for Reply Jozef.

I guess I did not explain properly.

I'm working with a HCM portal and I have a problem when I go to change the data for the time bank employee.

If I change the field action (in my language is "acão") then it does not change and back to the value it was before.

Then in debug it pass by 'HR_INFOTYPE_OPERATION' .

I need undesrtand why don´t change de action of bank employee.

I think could be a MP... program with z code like exit , but i need know how find it

inside standard code of 'HR_INFOTYPE_OPERATION'.

The parameters of HR_INFOTYPE_OPERATION' :

infty = 2001

number = 00029381

subtype = 0599

validityend = 20140801

validitybegin = 20140801

objectid = space

lockindicator = space

recordnumber = space

record  - with structure with data

operation = MOD











0 Kudos

if you want to find the main program for a specific infotype - in your case it is MP*2001*

But 2001 could be a bit more complex. Is it a customer program that does this operation? Does HR_INOFTYPE_OPERATION return any messages for you? If it is a customer program - is a COMMIT called after the data change?

0 Kudos

Hi Jozef

I search in all programs mp :

MP200110

MP200115

MP20011D

MP20011R

MP20011RU

MP200120

MP200125

MP20012R

MP20012RU

MP200130

MP200135

MP20013F

MP20013R

MP20013RU

MP200140

MP200145

MP20014D

MP20014F

MP20014GBPS

MP20014Q

MP20014R

MP20014RU

MP2001FS

But i don´t find and it don´t be change.

0 Kudos

HR_INOFTYPE_OPERATION returns no message.

raymond_giuseppi
Active Contributor
0 Kudos

Did you (in sequence)

  • Lock the employee record, e.g. Call FM BAPI_EMPLOYEE_ENQUEUE or HR_EMPLOYEE_ENQUEUE
    • When failure:  raise error
  • Refresh memory : Call FM HR_PSBUFFER_INITIALIZE (in case of mass update)
  • Try to update the data : Call FM HR_INFOTYPE_OPERATION
    • When failure: Call FM BAPI_TRANSACTION_ROLLBACK, raise error
  • Commit the data : Call FM BAPI_TRANSACTION_COMMIT (if you used NOCOMMIT parameter)

NB: If you don’t find/understand an error, try to call HR_INFOTYPE_OPERATION with DIALOG_MODE = 1 or 2.

Regards,

Raymond

0 Kudos

Thanks for reply Raymond.

HR_EMPLOYEE_ENQUEUE return nothing.


I'm going to put this  dialog in function , but what is it ?How work it?

0 Kudos

I inserted the dialog but don´t return nothig.

DATA:dialog_mode1 TYPE  c VALUE 1.

* Update Infotype

   CALL FUNCTION 'HR_INFOTYPE_OPERATION'

     EXPORTING

       infty         = p_pskey-infty

       number        = p_pskey-pernr

       subtype       = p_pskey-subty

       validityend   = p_pskey-endda

       validitybegin = p_pskey-begda

       objectid      = p_pskey-objps

       lockindicator = p_pskey-sprps

       recordnumber  = p_pskey-seqnr

       record        = p_record

       operation     = p_operation

       nocommit      = ' '

*Teste ronaldo alves 22.09.2014

       dialog_mode   = dialog_mode1

     IMPORTING

       return        = p_return.

0 Kudos
  • So no error messages are raised, try with 2 for any warning/status message.
  • When you test from portal, I would suggest you execute a trace (ST01) to look for authority-check failures.

NB: HR_EMPLOYEE_ENQUEUE, or equivalent BAPI, just locks the employee record.

Regards,

Raymond

0 Kudos

Ok Guys

Other abap tried change a field key of p2001 and use modify then the subty is wrong.

I deleted  the record and inserted and worked by function.

Thanks guys.