Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Selecting X TOP records
Message
 
 
To
11/10/2004 11:55:42
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00950435
Message ID:
00950507
Views:
12
>
>Yes, DISTINCT, ORDER BY and GROUP BY are not optimized.
>
>Use a ordered SCAN + buffer + INSERT
>
>* General fields are not supported
>SELECT * FROM MYORDERS WHERE .F. INTO CURSOR result READWRITE
>USE MYORDERS AGAIN ORDER TAGORDERNO
>SCAN NEXT 10
>    SCATTER MEMO TO aBuffer
>    INSERT INTO result FROM ARRAY aBuffer
>ENDSCAN
>USE
>SELECT result
>
Thank you so much for the suggestion and the code. As I mentioned in another message, I am creating this query from ASP.NET page (via OleDb driver) so I will have to see if I can use SELECT and SCAN there.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform