Ask a Question related to ASP Database, Design and Development.
-
Irene #1
Best athletes and not best scores. Problem with SQL command
Hi all,
I have set up a simple VB program (and later on an ASP interface) to
manage an Athletics database. I'm using Access 2000.
To simplify, I have the Athletes, the Competitions and the Scores
tables.
When I want to list of the best scores/ranking, I just do:
[1]SELECT TOP <how-many-best> AthletesName, Competitiondate,
CompetitionPlace, Score
FROM Scores INNER JOIN Competitions ... INNER JOIN Athletes ...
ORDER BY Score [DESC]
([DESC] is present if the scores are measured in times and not if they
are lengths)
I come into a problem whehter I want to list the best athlets, so to
say listing just the best results for each Athlet.
If I add a group by Athletsname parameter in the SQL, I am not any
longer able to display Competitiondate, CompetitionPlace because they
are not part of the aggregate function. :-(
So to say, I can only do:
---
[2a]SELECT TOP <how-many-best> AthletesName, Min(Score)
FROM Scores INNER JOIN Competitions ... INNER JOIN Athletes ...
GROUP BY AthletsName
ORDER BY Min(Score)
for scores in time
[2b]SELECT TOP <how-many-best> AthletesName, Max(Score)
FROM Scores INNER JOIN Competitions ... INNER JOIN Athletes ...
GROUP BY AthletsName
ORDER BY Max(Score)
for scores in lenght
---
How can I do, which SQL command can I use to be able to view all the
fields of the first SQL with just the best Athletes and not all the
best scores?
Many thanks for your replies.
Best regards,
Irene
Irene Guest
-
Sending Scores
Hi I have a quiz page which has 16 questions (interactions) and a 'Finish Quiz' Button which presents the results by simply using {G01.score +... -
Coursebuilder - 5 text areas for 5 possible scores. Eachpossible answer has its own text area
I'm trying to build an inventory form that has different point values for each possible answer for a particular question. there will be 5 possible... -
Coursebuilder recording scores
I used the sample data_tracking_xxx.xxx code supplied and my results are being correctly stored via an .ASP to a SQL database - life is good. But... -
game scores
hi does anyone know where i can get free java and flash games? and also how do i get those game scores to go onto my server? is there anyway please... -
Save Quiz scores on the users hard drive
I have developed a whole series of quiz?s using the Flash Learning extensions. These are part of our CBT refresher certification program for the...



Reply With Quote

