View Single Post
  #2 (permalink)  
Old 05-24-2006, 12:02 AM
alexfr alexfr is offline
Junior Member
 
Join Date: May 2006
Posts: 24
alexfr is on a distinguished road
Default MySQL answer. Re: List players by numbers of points?

[sql]SELECT p.lastname, p.firstname, SUM(r.value) AS Total, MAX( r.value) AS Maximum, p.birthdate
FROM player p INNER JOIN Resuls r ON p.id_player = r.id_player
GROUP BY p.lastname, p.firstname, p.birthdate , p.id_player ORDER BY Total DESC, Maximum DESC, birthdate ASC[/sql]
Reply With Quote