DJDaveMark
Programmer
Hi all,
I'm fairly new to SQL & I was wondered if there was a single SQL satement that would create something like the following table...
However these are all the best results for every race & every person in the database.
At the moment I'm querying the best result for all of the people in a single race then using some programming to do this for every race. This is proving to be very hard to maintain.
The tables are people, race_names & results
Any rough help will be much appreciated, even if that means saying "it can't be done!".
Thanks, DJDaveMark
I'm fairly new to SQL & I was wondered if there was a single SQL satement that would create something like the following table...
Code:
race1 race2 race3 race4
a. person 9 8 8 8
b. person 5 5 4 1
c. person 9 7 4 7
d. person 4 8 5 4
However these are all the best results for every race & every person in the database.
At the moment I'm querying the best result for all of the people in a single race then using some programming to do this for every race. This is proving to be very hard to maintain.
The tables are people, race_names & results
Any rough help will be much appreciated, even if that means saying "it can't be done!".
Thanks, DJDaveMark