Hey, i was wondering if it was possible to find the sum of all the values in certain row and than find the max value of all of them. I have the following code, but it only grabs the largest value from all the rows, is it possible to sum all them, and than grab the max based on the persons playerid?
$result = mysql_query("SELECT gamertag, goals FROM player_stats WHERE goals = (select Max(goals) from player_stats)GROUP BY playerid; ");
-----------------------------------------------------
Is it also possible to grab a profile picture from another table based on the code above?