Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL select is slow in large tables
Message
From
19/06/1998 11:09:31
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
SQL select is slow in large tables
Miscellaneous
Thread ID:
00109911
Message ID:
00109911
Views:
77
I have this table with about 90,000 records. The table is about 47 mb in size.Some of the fields are Invoice number, invoice date, active flag. If I do a select on these fields as so:

SELECT inv_number from INVTable WHERE YEAR(inv_date) = 1997 and REC_active into a cursor/table/array

There is an index on inv_number and the table is type FPW2.6

The result set is about 30000 records. In VFP 5.0a this is slow. Takes about>2 mins and sometimes runs out of memory if into an array. I read somewhere some time ago that there is a sys() function that improves the memory management of vfp and speeds up the select.

I dread to think what would happen if I needed to extract from 2 tables using a join condition!

Does someone out there working with large tables have any ideas? A view is not what I'm looking for, parametised or otherwise.

Thanks in advance

Bernard
Next
Reply
Map
View

Click here to load this message in the networking platform