Chester Friesen wrote:
>  I need all the 
> records in the table to show in the report sorted by the order that the 
> above came up with. i.e., sorted by the Names, but in the order of the 
> Totals. I hope I'm making sense! Actually the example below should be 
> descending instead of ascending, but that's an easy part.
Actually, if you have VFP9, you can do it with one query:

SELECT A.Rider, A.dDate, A.nScore, ;
      (Select SUM(nscore) FROM foobar B WHERE b.rider = a.rider) ;
 FROM foobar A;
 ORDER BY 4 desc,1



_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to