on 06-18-2008 7:49 AM
hi gurus,
i am new to infotype and subtype.
i have following requierement and needs your help.
thanks for the same in advance.
1) I have to read subtype stat. (how one can read a subtype please let me know it.)
2) then i have to delimit the same(subtype stat), to same date.
3) I hav being ask to use function module HR_INFOTYPE _OPERATION.
I have no idea about it, help me with this.
Thanks.\
Adi.
Point will be surely awarded.
HI,
in the fm HR_INFOTYPE _OPERATION
the parameters are:
INFTY - Infotype number which you want to read
NUMBER - Employee Number
SUBTYPE - Subtype .. here in you case pass 'STAT'
and in return you will get the employee data for the passed infotype and the subtyp e'STAT'.
Hope this helps.
Reward if helpful.
RSS
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi there
thanks for your reply
but i m little confused
i have to read the subtyoe fast and then use the FM
with operation "MOD".
to update a stucture.
so please tell me do i have to use this function module twice.
one for read and another to update the structure.
please tell me the operation value also for reading of subtype
adi.
hi
i did not get you.
Could you please help in me in detail.
You suggested not use to use fm twice, but my requirement is to read the subtype first and if there is any data present then i have to modify the stucture.
suggest me who to do the same.
this is what need
i need to read the subtype first and then i have to update the stucture using the fm hr_infotype_operation
thanks in advance.
Adi.
hello All,
please help me, i am new to hr abap.
i hav a object to deliver.
in that i hav to read subtype of a infotype.for that i hav being advice to use
hr_read_infotypr function module.
i dont hav good ides about it.
help me on this please.
please let me know wat value i have to put in the importing and exporting parameter.
CALL FUNCTION 'HR_READ_INFOTYPE'
EXPORTING
tclas = 'A'
pernr = wa_pa0006-pernr
infty = '0006'
BEGDA = '18000101'
ENDDA = '99991231'
BYPASS_BUFFER = ' '
LEGACY_MODE = ' '
IMPORTING
SUBRC =
TABLES
infty_tab = HERE WHAT I HAVE TO PUT " WHAT STRUCTURE
EXCEPTIONS
INFTY_NOT_FOUND = 1
OTHERS = 2
.
IF sy-subrc <> 0.
I hav use a structure which is of type pa0006 as i am reading the infotype 0006 subtypes.
but in the subtype fields it showing infotype value i.e 0006 and not a subtype value.
can any 1 tell me why this is happening.
points will be surely awared.
adi./
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
in TABLES parametner you have to pass the Internal table which you have declared above, that internal table will collect all the details of that employee..
i.e.
Data: it_p0006 type table of p0006,
wa_p0006 type p0006.
in FM, you need to pass the above declared itab it_p0006
TABLES
infty_tab = it_p0006.
then, FM will collect all the info based on the dates and keep into the it_p0006.
You can check in debugging or loop that itab and display..
Best Regards,
Ratan.
Delimit means to change the end date to what ever user requires
Put the required infotype, subtype , end date as in the code given below
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = '0169'
subty = 'RRSP'
number = p_pernr
record = l_p0169
validitybegin = '20021001'
validityend = '99991231'
operation = 'INS'
* dialog_mode = '0' "Use default
* nocommit = '1' "Use default
IMPORTING
return = l_bapireturn
key = bapipakey_tab.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Input your infotype values and date specs
If there is a record in the specified range.
Choose what record to change and input into the 'HR_INFOTYPE_OPERATION'
get pernr.
CALL FUNCTION 'HR_READ_INFOTYPE'
EXPORTING
* TCLAS = 'A'
pernr = pernr-pernr
infty =
* BEGDA = '18000101'
* ENDDA = '99991231'
* BYPASS_BUFFER = ' '
* LEGACY_MODE = ' '
* IMPORTING
* SUBRC =
tables
infty_tab =
* EXCEPTIONS
* INFTY_NOT_FOUND = 1
* OTHERS = 2
.
IF sy-subrc <> 0.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty =
number =
* SUBTYPE =
* OBJECTID =
* LOCKINDICATOR =
* VALIDITYEND =
* VALIDITYBEGIN =
* RECORDNUMBER =
record =
operation =
* TCLAS = 'A'
* DIALOG_MODE = '0'
* NOCOMMIT =
* VIEW_IDENTIFIER =
* SECONDARY_RECORD =
* IMPORTING
* RETURN =
* KEY =
.
ENDIF.
You need to reward so that people will be encouraged to answer your questions
hi Sriram,
The function module suggest by you to read the infotype.
But i have to read subtype.
Please tell me how to read the subtype of a infotype.As i have tio check first that the subtype and then to
update the structure.
please help me as soon as possible.
hI ALL PLEASE REPLY ME FAST.
I do not the waty the out.
please help how to read the subtype contain of the infotype
Adi /.
Edited by: anuj adi on Jun 20, 2008 2:32 PM
say for example you are reading Infotype 0006
You are passing internal table pa0006 in the function module
Now you have the values in the internal table pa0006
to read subtype '0001'
with date range 01.01.1900 - 31.12.9999
loop at pa0006 where subty = '0001' and begda ge 01.01.1900 and endda le 31.12.9999.
endloop.
* If you want one record use read statement
read table pa0006 with key subty ='0001'.
Hello Sriram,
thanks alot for all your help
But i have few more problem
1)Could you please tell me
after using fm hr_read_operation with operation MOD
where we can see the change, i means which dat base table the function module update.
2)In function module hr_read_infotype
the parameter
TABLES
infty_tab = infty_tab.
what should be the structure of the infty_tab please help me on this too
please tell me about this in more detail as u said i have to make a loop
a read on this table to check my subtype of the info type.
Please reply in as soon as possible.
please help me with a simple report
which uses both these f.m
i mean a workin report.
Thanks
Adi /.
..................
Point have being awarded for the last help
and ll be awaded for all your help.
note: data: it1_pa0006 like p0006 occurs 0 with header line.
Edited by: anuj adi on Jun 23, 2008 8:24 AM
Edited by: anuj adi on Jun 27, 2008 8:48 AM
Edited by: anuj adi on Jul 10, 2008 9:34 AM
User | Count |
---|---|
104 | |
12 | |
11 | |
6 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.