‎2007 Aug 31 4:18 AM
I want to print sum of all amount , i have 3 fields i want to sum them at the bottom of the report.these 3 fields are in a internal table.
how do i do?
‎2007 Aug 31 4:29 AM
Hi,
LOOP AT itab.
AT LAST.
SUM.
WRITE : itab-field1, itab-field2....
ENDAT.
Thanks and Best Regards,
Vikas Bittera.
**Reward if useful**
‎2007 Aug 31 4:29 AM
Hi,
LOOP AT itab.
AT LAST.
SUM.
WRITE : itab-field1, itab-field2....
ENDAT.
Thanks and Best Regards,
Vikas Bittera.
**Reward if useful**
‎2007 Aug 31 5:20 AM
hi vikas
thanks for giving me solution
after writing this code there is another errror occurs
in debug mode SUm is occurring but in my output its overlapping the 2nd field value and does display the sum of result
regards soumendra
‎2007 Aug 31 5:25 AM
hi vikas
thanks for giving me solution
after writing this code there is another errror occurs
in debug mode SUm is occurring but in my output its overlapping the 2nd field value and does not display the sum of result
regards soumendra
‎2007 Aug 31 6:26 AM
Hi Sumendra,
You need to adjust the WRITE statement..
Just give the positions too..
WRITE 😕 itab-field1,
20 itab-field2,
35 itab field3.
Adjust the values 20, 35 to display your o/p properly..
Thanks and Best Regards,
Vikas Bittera.
**Reward if useful**
‎2007 Aug 31 6:51 AM
‎2007 Aug 31 7:00 AM
hi vikas
shall i copy my code and screen shot of my o/t send to u
‎2007 Aug 31 7:01 AM
‎2007 Aug 31 7:02 AM
Hi ..
If you paste ur Code.. i can trace the probelm..
regards,
Varma@infyTree.
‎2007 Aug 31 7:06 AM
Hi,
vikas.bittera@gmail.com
Thanks and Best Regards,
Vikas Bittera.
**Reward if useful**
‎2007 Aug 31 4:31 AM
hi,
check this samole code
data : l_cust like kna1.
data: l_sales like vbak occurs 0 with header line.
vbeln type vbak-vbeln,
erdat type vbak-erdat,
netwr type vbak-netwr,
end of l_sales.
data amt_sum like vbak-netwr value 0.
parameters : cno like kna1-kunnr.
select single * from kna1 into corresponding fields of l_cust where kunnr = cno.
select *
from vbak into corresponding fields of table l_sales where kunnr = cno.
loop at l_sales.
amt_sum = amt_sum + l_sales-netwr.
endloop.
‎2007 Aug 31 6:58 AM
Hi Soumendra,
I am not getting the issue.. wht do u mean by overlapping with field 2??
can you copy and paste the o/p?
Thanks and Best Regards,
Vikas Bittera.
**Reward if useful**