Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SELECT TOP 50 behavior
Message
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
00021472
Message ID:
00021495
Views:
41
>This is one interesting behavior.
>
>SELECT NAME,MESSAGE FROM MESSAGE ORDER BY 2 DESCENDING TOP 50 INTO CURSOR TEMP
>
>The question is:
>
>Do you think we will have the first 50 name having the highest number of message or not?
>
>My result is given 51 because I have 3 people having the same number of message from 49, 50 and 51 ranked.
>
>How can we use TOP 50 and have only the first 50?

Maybe a 'tiebreaker' field in the order by? The SQL is doing as it should, it doesn't want to arbitrarily choose one name over another...
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform