07-01-2007 6:41 PM
hallow
i use Fm 'HR_INFOTYPE_LOG_GET_DETAIL' and i wont to move table infty_tab_after (field data)in function to structre like 0001,0002
i herad that i can do it but i dont sucsses?how can i do that
DATA :wa_p0000 TYPE p0000.
IF wa_lcl_pers_tab-infty = '0000'.
wa_p0000 = infty_tab_after."<i><b>here i have error</b></i>
Endif.
regards
<u></u>
07-01-2007 7:15 PM
Hi Shnya,
Your question is not clear but what i understand ..
You can move interntable values to work area within loop.
Thanks
Seshu
07-01-2007 7:15 PM
Hi Shnya,
Your question is not clear but what i understand ..
You can move interntable values to work area within loop.
Thanks
Seshu
07-01-2007 7:27 PM
hi seshu
to loop into wwork area i now,but here i have table infty_tab_after and (in fm 'HR_INFOTYPE_LOG_GET_DETAIL)and i wont to move this table to structre
p0000(this is structre in hr pa0000) i heard that i can do that but i dont now how?
regards
this is what i try but its not true.
DATA :wa_p0000 TYPE p0000.
IF wa_lcl_pers_tab-infty = '0000'.
wa_p0000 = infty_tab_after."here i have error
Endif.
regards
07-01-2007 9:53 PM
Hello Shnya
You have to convert the semi-transparent type PRELP to its corresponding transparent type (e.g. P0000). In order to to this you should use the following coding:
DATA:
ls_prelp TYPE prelp, " semi-transparent infotype structure
ls_p0000 TYPE p0000,
lt_p0000 TYPE STANDARD TABLE OF p0000.
" Retrieve data from fm HR_INFOTYPE_LOG_GET_DETAIL
...
IF wa_lcl_pers_tab-infty = '0000'.
LOOP AT infty_tab_after into ls_prelp.
* Convert: semi-transparent -> transparent infotype
CALL METHOD cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
EXPORTING
prelp = ls_prelp
IMPORTING
pnnnn = ls_p0000.
APPEND ls_p0000 TO lt_p0000.
ENDLOOP.
ENDIF.
For an example have a look at my Wiki report:
<a href="hhttps://wiki.sdn.sap.com/wiki/display/Snippets/UnifiedAccesstoAllHR+Infotypes">Unified Access to All HR Infotypes</a>
Regards
Uwe