Hi everybody,
The following Select statement take to much of time.
first i am taking the doc.no based on the date interval
and after that with that doc.no and other criteria i am picking records
from bseg table but it taking much time.
please help me.
select belnr from bkpf into table it_doc
where bldat in s_bldat
and ( blart = 'CJ' or blart = 'KR'
or blart = 'KT' or blart = 'RE' or blart = 'RN' ) .
<b>
if not it_doc[] is initial.
sort it_doc by docno.
select * from bseg into table it_bseg
for all entries in it_doc
where belnr = it_doc-docno
and mwskz = p_mwskz
and gjahr = p_gjahr
and ( bschl = '40' or bschl = '31' OR BSCHL = '29' or
bschl = '83' or bschl = '86' ).
endif.</b>
Thanks in advance
V.Srinivasa rao.