08-20-2007 6:49 AM
Hi friends,
This is simple but while implimenting its not comming as reqired..
I want calculate the qunatity by locations... from MSEG table .. U will get all fields..
how can i do this please..
iwant pass this these two fields to another table..
please suggest me..
if used AT end of..
sum..
end at..
i have to use write..
with out write stmt.. how can u do thet..
please send me the code.. if possible..
THanks in Advance..
08-20-2007 6:51 AM
Hi,
you can also use
on change of
try this
data: itab like ekko occurs 0 with header line.
data: itab1 like ekpo occurs 0 with header line.
select * from ekko into table itab up to 20 rows.
if itab[] is not initial.
select * from ekpo into table itab1 for all entries in itab where ebeln = itab-ebeln.
endif.
sort : itab by ebeln,
itab1 by ebeln ebelp.
loop at itab1.
on change of itab1-ebeln.
write:/ itab1-ebeln .
endon .
write: /20 itab1-ebelp.
endloop.
thanks & regards,
Venkatesh
08-20-2007 6:54 AM
Hi,
i have given a wrong thing to you..
you can use the collect statemetn
whcih can sum up the numeric field
like
loop at itab.
itab1-field = itab-field. ( some characterfield)
itab1-field1 = itab-field. ( numeric field)
collect itab1.
endloop.
thanks & regards,
Venkatesh