I have a doubt about select single statement in this particular statement below.
i have the code which goes this way.
loop at itab.
concatenate *year *materail no * item type into dummy variable.
select single dmbtr from bsis into itab-dmbtr where xref3 = dummy variable and belnr = itab-migodoc and gjahr = itab-mjahr and hkont = '0000123'.
clear dummy variable.
the bsis table has around 4,000,000 records.
The report when executed goes smoothly till the point where the above select statement is encountered.
my question is does it take time to execute because of so many records ?
If not then why dies it take a lot of time to execute a single select statement ?
and how can i optimise the time consumed by this select query or report. ?
Moderator message: please understand the basic concept of using primary or secondary indexes in your queries, you will sure find the missing field in your where-clause, read the sticky threads of this forum.
Edited by: Thomas Zloch on Nov 20, 2010 5:31 PM