‎2008 Feb 04 5:21 AM
Select all the PRGRP, WERKS, ANTEI and NRMIT from table PGMI based on product group and plant from selection screen store into one internal while storing, Multiply ANTEI = ANTEI * 100 .
can any one tel me how can i multiply antei by 100
‎2008 Feb 04 5:25 AM
Select all the PRGRP, WERKS, ANTEI and NRMIT from table PGMI based on product group and plant from selection screen store into one internal while storing, Multiply ANTEI = ANTEI * 100 .
Loop the ITAB
multiply the ANTEI = ANTEI * 100
endloop.
Narendra
‎2008 Feb 04 5:25 AM
hi,
Use a select query to get all reqd fields in internal table itab.
then use following code.
loop at itab.
itab-antni = itab-antni * 100.
modify itab.
endloop.
‎2008 Feb 04 5:25 AM
Hi
loop at itab.
multiply itab-ANTEI by '100'.
modify itab.
endloop.
Cheers,
Will.
‎2008 Feb 04 5:26 AM
Hi
After the select statement.
loop at ANTEI = ANTEI * 100 .
ANTEI = ANTEI * 100 .
MODIFY ANTEI = ANTEI * 100 .
ENDLOOP.
‎2008 Feb 04 5:28 AM
Hi,
you can to it in this way too
SELECT F1
F2
F3
into wa from DDT WHERE XYZ.
WA-F1 = WA-F1 * 100.
APPEND wa to itab.
endselect.
Rewards if helpful,
GAURAV J.
‎2008 Feb 04 5:31 AM
select PRGRP, WERKS, ANTEI , NRMIT from pgmi into table t_pgmi where prgrp and werks acording to the selection-screen .
Loop at t_pgmi into wa_pgmi.
wa_pgmi-antei = wa_pgmi-antei * 100.
modify t_pgmi from wa_pgmi transporting antei.
endloop.
‎2008 Feb 04 5:38 AM
Hi
doing a loop at your internal table is mandatory.. so do it effeciantly..
internal table is itab.
work area of this itab is wa_itab.
field-symbols:<fs_itab> type wa_itab.
loop at itab assigning <fs_itab>.
<fs_itab>-ANTEI = <fs_itab>-ANTEI * 100.
"<<<<<<<<you are eliminating a modify itab statment here..by using <fs>
endloop.
‎2008 Feb 04 6:35 AM
select PRGRP
WERKS
ANTEI
NRMIT
from PGMI
into <internal table>
where <Condition>
if sy-subrc eq 0.
<internal table>-antei = <internal table>-antei * 100
append <internal table>-antei .
endif.
endselect.
or
LOOP AT <internal table>.
<internal table>-antei = <internal table>-antei * 100.
MODIFY <internal table>FROM <internal table>
TRANSPORTING antei.
ENDLOOP.