Hi,
I want to speed up the select process by using an index. I have tried the following two programs. It seems that there is no improvement in program2. Actually, Program2 is slower than Program1 as it needs to generate the index on line. Could someone please tell me how to use the index with SELECT properly? Note that Servhist.dbf is about 100Mb.
Program 1
Use Servhist excl
select * from Stock where InvoiceNo=="E68712" into cursor Ctemp
browse
Program 2
Use Servhist excl
index on InvoiceNo to InvNo
set index to InvNo
select * from Stock where InvoiceNo=="E68712" into cursor Ctemp
browse
Thanks in advance.
Peter
I want to speed up the select process by using an index. I have tried the following two programs. It seems that there is no improvement in program2. Actually, Program2 is slower than Program1 as it needs to generate the index on line. Could someone please tell me how to use the index with SELECT properly? Note that Servhist.dbf is about 100Mb.
Program 1
Use Servhist excl
select * from Stock where InvoiceNo=="E68712" into cursor Ctemp
browse
Program 2
Use Servhist excl
index on InvoiceNo to InvNo
set index to InvNo
select * from Stock where InvoiceNo=="E68712" into cursor Ctemp
browse
Thanks in advance.
Peter