Use this function module which gives all wage type details for infotype 0008.
RP_FILL_WAGE_TYPE_TABLE_EXT
to read the amounts corresponding to the wage types
use do .. varying ... enddo ...
data : it_pa0008 like pa0008 occurs 0 with header line.
data : begin of it_temp occurs 0,
lga01 like pa0008-lga01,
bet01 like pa0008-bet01,
end of it_temp.
do 40 times
varying it_temp-lga01 from it_pa0008-lga01 next it_pa0008-lga02
varying it_temp-bet01 from it_pa0008-bet01 next it_pa0008-bet02.
write case here to get the corresponding amounts
case it_temp-lga01.
when '/101'.
v_amt1 = it_temp-bet01.
when '/100'.
v_amt2 = it_temp-bet01.
endcase.
enddo.
Hi,
please check thiscode
call function 'RP_FILL_WAGE_TYPE_TABLE_EXT'
exporting
appli = 'P'
pernr = p0467-pernr
infty = pinfty
SUBTY = PSUBTY
OBJPS = POBJPS
SEQNR = PSEQNR "QEAK100596
waers = sy-waers "XYMK097435
begda = datum
endda = datum
tables
pp0001 = p0001 "input
pp0007 = p0007 "input
pp0008 = p0008 "input
ppbwla = ppbwla "output
exceptions
error_at_indirect_evaluation = 1.
check sy-subrc eq 0.
loop at ppbwla.
if ppbwla-waers ne q0467-waer2.
perform convert_to_local_currency using
ppbwla-betrg ppbwla-waers
q0467-waer2 ppbwla-betrg
datum.
modify ppbwla.
endif.
endloop.
Ref program
MP046740
Thanks and regrds
Durga.K
thanks Durga for the answer ,
I am getting all the tabels p0001, p0007, p0008, ppbwla, p0230 blannk
can u help me further
i am calling FM like these
data: begin of ppbwla occurs 20.
include structure pbwla.
data: end of ppbwla.
DATA : ipa0008 TYPE STANDARD TABLE OF pa0008 WITH HEADER LINE,
ipbwla TYPE STANDARD TABLE OF PBWLA,
ipa0001 TYPE STANDARD TABLE OF p0001,
ipa0007 TYPE STANDARD TABLE OF p0007,
iPA0230 TYPE STANDARD TABLE OF PA0230.
in tables do i need to use internaln tables in FM or it is ok.
i.e CALL FUNCTION 'RP_FILL_WAGE_TYPE_TABLE_EXT'
EXPORTING
pernr = pernr-pernr
infty = '0008'
*subty = ipa0008-subty
*objps = ipa0008-objps
begda = ipa0008-begda
endda = ipa0008-endda
dlspl = ' '
TABLES
pp0001 = p0001
pp0007 = p0007
pp0008 = p0008
ppbwla = ppbwla
PP0230 = p0230
EXCEPTIONS
error_at_indirect_evaluation = 1.
Add comment