I Need to write one conversion which will move the district field data into city field data in infotype 6..
It need to apply for only one Specific country which can be identified by Employee Personnel Area..and it should be apply for all active , Terminated employee as well...
What is the best process so that i can catpure all the data records of employees of the Specific country?
my approacH is..
RP_PROVIDE_FROM_LAST P0001 space pn-begda pn-endda.
check p0001-weks = '5200'.
rp_provide_from_last p0006 space pn-begda pn-endda.
Loop at p0006.
move p0006 to T_p0006.
if ort01 is not initial
Move P0006-ORT01 TO T_P0006-ORT02.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
infty = '0006'
subtype = P0006-subty
objectid = P_record-objps
number = p0006-pernr "employeenumber
validityend = validityend
validitybegin = validitybegin
record = T_p0006.
recordnumber = p_record-SEQNR
operation = 'MOD'
nocommit = nocommit
dialog_mode = '0'
return = return_struct
key = personaldatakey
OTHERS = 0.
Is this using Loop is fine? or Using PROVIDE * from p0006 between PN-BEGDA AND PN-ENDDA
ENDPROVIDE is fine?
Is my code is accurate...Bapi_employee enque bapiemployee_deque i will add apart from that is this code is fine for my requirement or any additional need to take care to capture all the employee data ?
Edited by: saslove sap on May 5, 2009 12:20 PM