Application Development and Automation 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: 
Read only

hr infotypes

Former Member
0 Likes
1,599

hi all

is there a function module or bapi in hr that will have aedtm(changed on date) as the input parameter for selctions from hr infotypes.

any pointers to this will be really helpfull

regards

navjot

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,567

thanks for ur prompt reply

actually my senario is that i need to check wheather field from a certain infotype are changed or not based on that i need to proceed .

infotype concerned are pa0002 and pa0006

any pointers will be really helpfull

navjot

hi all

is there a function module or bapi in hr that will have aedtm(changed on date) as the input parameter for selctions from hr infotypes.

any pointers to this will be really helpfull

regards

navjot

11 REPLIES 11
Read only

suresh_datti
Active Contributor
0 Likes
1,567

There are a couple of function modules for the PD Infotypes ie

HR_CHECK_INFTY & RH_SHOW_LAST_CHANGE that use the AEDTM as an import parameter.. But there aren't any for the PA infotypes. What exactly is your reqt? If you are looking for the PA Infotype logs, pl take a look at the Std report RPUAUD00.

~Suresh

Read only

Former Member
0 Likes
1,567

I couldn't find any function modules. But you could write your own custom function module and do a select like this:

SELECT * FROM pa0001 APPENDING TABLE it_p0001

WHERE aedtm GE min_date

AND aedtm LE max_date.

In this case you would define it_p0001 as TYPE STANDARD TABLE OF pa0001 and declare the table pa0001 in a TABLES statement. I hope this helps.

- April King

Read only

Former Member
0 Likes
1,568

thanks for ur prompt reply

actually my senario is that i need to check wheather field from a certain infotype are changed or not based on that i need to proceed .

infotype concerned are pa0002 and pa0006

any pointers will be really helpfull

navjot

Read only

0 Likes
1,567

Then you are better off using the Infotype log..as a SELECT with AEDTM in the WHERE will not tell you which/what field was changed.. you can take a look at the following function calls & see if you can use them in your Program

HR_INFOTYPE_LOG_GET_DETAIL

HR_INFOTYPE_LOG_GET_LIST

~Suresh

Read only

0 Likes
1,567

Suresh is right, you can use the logged infotypes changes report for that. But you would have to have both of those infotypes (0002 and 0006) set up for logged changes. Check here in the IMG:

Personnel management --> Personnel administration --> Tools --> Revision --> Set up change document

If you can't find that path, go to transaction SM31 and use views V_T585A, V_T585B, and V_T585C to make the necessary changes.

- April

Message was edited by:

April King

Read only

0 Likes
1,567

hi

i am unable to find the menu path and having no idea abt how to go ahead from the transaction

plz explain

regards

navjot

Read only

0 Likes
1,567

Go to transaction SM31. Type in V_T585A and click on "Maintain". Now look to see if the two infotypes that you need are listed in the table. If they are not there, then you need to create entries for them. Click on the "New Entries" button. Enter the transaction class (A for employee data, B for applicant data) and the infotype number. Save your changes. Now go back to the main screen of SM31. Type in V_T585B and click on "Maintain". Look for your infotypes. If they are not there, click on the "New Entries" button. Enter the infotype number. Now you can specify which fields will cause an entry to be created in the log when they are changed on the infotype. If you are going to choose several fields that trigger an entry but you want to log them together, then they should have the same field group number. Enter a field group number and the field name. You can enter * for the field name if you want all fields of the infotype to trigger log entries for changes. Save your table changes and go back to the main screen of SM31. Enter V_T585C and click on the "Maintain" button. Look for your infotypes. If they are not there, click on the "New Entries" button. Enter the transaction class (again, A for employee or B for applicant), the infotype number, the document field group (the field group number you used in V_T585B), and a document type (S for short or L for long). Save your changes.

- April

Read only

0 Likes
1,567

hi april (if thts ur name)

thanks for the prompt reply

the loggin part is done but i can c the logged data in the standard report prog but the fm are still not returning anythin.

plz help in the above case

regards

navjot

Read only

0 Likes
1,567

Hi. Make sure you are using the function modules in the correct order. First call HR_INFOTYPE_LOG_GET_LIST to get a list of the log entries. Pass the transaction class, the begin date, and the end date. You should also enter personnel numbers and/or infotype number in the PERNR_TAB or INFTY_TAB to restrict which entries you get. Be sure to define these parameters the same way they are definied in the function module. This function module will return keys to you in parameter INFTY_LOGG_KEY_TAB. You can then loop through this and pass the key value to function module HR_INFOTYPE_LOG_GET_DETAIL to get the specific detail for a log entry. Check the value in exporting parameter REFERENCE from either function module to see what the return code is.

- April

Read only

0 Likes
1,567

HI APRIL

HOPE UR STILL THERE

I AM NT FETCHING ANYTHN FROM THE FIRST FM DUR TO A FIELD<b> REPID</b>

IT HAS A VALUE <b>SA</b> IN MY TABLE PCA4 WHILE ITS HARDCODED AS <b>LA</b>

HAVE MY MISSED SOMETHN IN MY SETTING SO THT THIS VALUE IS STORED AS LA

WEAITING FOR UR REPLY

REAGARDS

NAVJOT

Read only

0 Likes
1,567

Yes, the function module is hard-coded to use LA. Why is it SA in your table? I think you may need to set your documents to type L in view V_T585C in order to use these function modules.

- April