>Hi all
>I have a table XXX with 25 fields (ctype, nNum, ... filed25) and aprox 100.000 records and following code:
>
>scan for ctype=cvar1 and nnum=nvar2
>...
>endscan
>
>
>Recently this scan became very slow. I've indexed the table in cType and nNum to optimyze speed but it does no work...
>Any ideas would be great.
>
>Thank's in advance,
>NPedro
set order to tag cType
=seek(m.cVar1)
scan while ctype = m.cvar1 for nnum = m.nvar
...
endscan
If it is still slow then seek for other causes (not using m. prefix is by itself a cause to slow down a loop)
Cetin