‎2007 Sep 12 2:48 PM
Hi ,
Here is a new requirement in HR Transaction PA30 which calls an include.
do znumber_of_lgart_in_p0008 times
varying zstr_p0008 from rs_p0008-lga01 next rs_p0008-lga02
varying zstr_indbw from rs_p0008-ind01 next rs_p0008-ind02.
but zstr_p0008 and rs_p0008-lga01 ... or structures.
It says "type incompatible ERROR".
‎2007 Sep 12 2:53 PM
Here is an example of how we have this for infotype 0041. It probably has to do with your variable declarations:
data: w_dar LIKE pa0041-dar01,
w_dat LIKE pa0041-dat01.
DO 12 TIMES VARYING w_dar FROM p0041-dar01 NEXT p0041-dar02
VARYING w_dat FROM p0041-dat01 NEXT p0041-dat02.You must ensure that zstr_p0008 is declared like rs_p0008-lga02 and zstr_indbw is declared like rs_p0008-ind02.
Best Regards,
Chris H.
‎2007 Sep 13 5:59 AM
Chris ,
in my case w_dar is a structure .
data: begin of zstr_p0008,
lgart like p0008-lga01,
betrg like p0008-bet01,
anzhl like p0008-anz01,
ein like p0008-ein01,
opken like p0008-opk01,
end of zstr_p0008.
and the error happens in the following code as type incompatible,
do znumber_of_lgart_in_p0008 times
varying zstr_p0008 from rs_p0008-lga01 next rs_p0008-lga02
varying zstr_indbw from rs_p0008-ind01 next rs_p0008-ind02.