comboy
Instructor
- May 23, 2003
- 226
Hi all,
I'm just starting to look and php & mysql so bear with me please.
I was wondering how I can use the results of one query to generate results for another query.
I have two tables trainer and schedule the trainer primary key (id) is a forigen key of schedule.trainer row.
What I'm trying to do is have a table in which one row is the trainer id from the trainer table(done this) and the rows below select information from the schedule table based on the trainer id in the row above. To do this I think I'll need another query in which the trainer id is taken from the first query to help build the second query but don't know how.
exampe
trainerid | trainerid|
Date | Date |
Comment | Comment |
Thanks in advance
Graham
I'm just starting to look and php & mysql so bear with me please.
I was wondering how I can use the results of one query to generate results for another query.
I have two tables trainer and schedule the trainer primary key (id) is a forigen key of schedule.trainer row.
What I'm trying to do is have a table in which one row is the trainer id from the trainer table(done this) and the rows below select information from the schedule table based on the trainer id in the row above. To do this I think I'll need another query in which the trainer id is taken from the first query to help build the second query but don't know how.
exampe
trainerid | trainerid|
Date | Date |
Comment | Comment |
Thanks in advance
Graham