Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Last 10 records based on a condition
Message
From
31/12/2001 17:43:25
Dragan Nedeljkovich
Now officially retired
Zrenjanin, Serbia
 
 
To
31/12/2001 11:23:57
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00599284
Message ID:
00599521
Views:
41
>>>>No, with order by clause it will have to create result set first, order it and than pick TOP N records from it. The same way it works in VFP.
>>>
>>>Well, as my result is the first most recent, thus the last 10 in the table which matches the condition, it means that no matter if that would be in Visual FoxPro or in SQL Server, it'll take some time.
>>
>>Correct.
>
>Ok, thanks for the clarification. I ended up not to do that option finally. :)

A slight workaround - if you had a timestamp field, you could use the TOP 10 on that field, plus a Wherre clause, assuming it's a real timestamp, so the last 10 records would have the 10 latest datetimes.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform