Then, I would use CFOUTPUT GROUP to layout the page. You don't need a
GROUP BY in your query, but you will need an ORDER BY to ensure the
headings appear correctly.
________________________________
From: Jeff Fongemie [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 27, 2004 2:05 PM
To: CF-Talk
Subject: I'm stumped.
Hey everyone.
I'm stumped.
I need to be able to display a list of bicycle races, and under
the ra
ce list the riders names and positions. I'd like to have two
tables so
the admin adding the data only needs to enter the race name and
date
once, then adds the riders in a seperate table linked by a
raceid.
Right now I've got two tables, one for the races, one for riders
linke
d by common field raceid.
The above seems fine, but I'm having trouble querring and
displaying r
esults. What I need should look like this:
RACE NAME, DATE, COUNTRY
ridername, place, team
ridername, place team
ridername, place team
RACE NAME, DATE, COUNTRY
ridername, place, team
ridername, place, team
and so on.
Display the race info once, and then the riders under that.
Do I join at the query? Group at the query? Group at the output?
This shows me everything:
SELECT *
FROM riders, races
WHERE riders.raceid=races.raceid
I wish I could do this:
SELECT *
FROM riders, races
WHERE riders.raceid=races.raceid
Group By Raceid
Any suggestions would be most appraciated.
Thanks,
JF
________________________________
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

