Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
What is more efficient of the two
Message
From
12/07/2006 06:26:19
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 8 SP1
Database:
MS SQL Server
Miscellaneous
Thread ID:
01135592
Message ID:
01135607
Views:
9
My answer is simple: try both approaches with reasonable data, and see for yourself.

I have seen so many situations where the "slow" solution has been the fastest in real life. A few months ago I had a long discussion here at UT with a programmer who simply refused to try my approach, because he "knew" that it would be too slow. The fact that I used the technique I described in my own webshop with a 900MB table with 9 million records, and with an average response time of less than one second, did not impress him. He needed less response time than 10 seconds, and he insisted that my technique simply could not work. Conclusion: theory and practice is two different things.

>Hi all
>
>What is more efficient:
>
SQL PT dataset (variable no of records but within a range of records)
>INDEX on a field
>
>SCAN
>   SEEK(in "MySQLPTCursor")
>   Do other stuff
>ENDSCAN
>
>
>SCAN
>   SQL PT single record as needed
>   Do other stuff
>ENDSCAN
>
>Please advise.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform