Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Selecting the last match
Message
From
18/06/2001 09:34:01
Cindy Winegarden
Duke University Medical Center
Durham, North Carolina, United States
 
 
To
18/06/2001 06:21:33
Jimi Lee
Pop Electronic Products Ltd.
Hong Kong, Hong Kong
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00520445
Message ID:
00520554
Views:
13
Jimi,

This should work for Fox2x tables also. Exactly how do you know what the "last" record is? By Date? Key value? Record number?

>Hi Garrett,
>
>Thanks for the reply, but how if my table is in fox2x format? I tried your suggestion but it still come out with the first match record..
>
>Please help! thanks a lot!
>
>
>>>hi all,
>>>
>>>I have this query:
>>>
>>>Select a, b, c from MyTable;
>>>  into array MyArray;
>>>  where a=MyKey
>>>
>>>
>>>If there are serveral matches in the table, how should I modify this query in
>>>order to get the last matched one?
>>
>>One way to do this would be to use the TOP 1 and the ORDER BY myField DESCENDING clauses.
Previous
Reply
Map
View

Click here to load this message in the networking platform