Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Highest Value of a Field in a Table
Message
 
 
To
02/10/2007 09:34:02
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Novell 6.x
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01257876
Message ID:
01257882
Views:
18
>>>I was just wondering if anyone knows of any prebuilt functions in VFP that will quickly search through a selected field in the table and find the record which has the highest value of that field? If not, I can always write my own, but I just thought I would check to see if there was already one that I have never run across yet.
>>
>>Does Select Max(fieldname) from table work for you?
>
>Sorry, that should have been select max(fieldname), recno() as recordno from table.

It's not going to work because RECNO() may not be from the record with max(fieldname).
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform