This topic is locked
[SOLVED]

 Three tables..one list

8/16/2005 12:46:54 AM
PHPRunner General questions
jwoker author

I have the following table structure:
user.id

user.firstname

user.lastname

user.email
course.id

course.name
students.id

students.userid

students.courseid
I need a list that gives me all of the students names and email for any given course. How can I achieve this?

admin 8/16/2005

Hi,
you need to set master-detail relationship between course and students tables.

Set course as Master table, students - as Detail table. Use id field as primary key and courseid as foreign key.
Choose Edit as format - Lookup wizard for userid field on the Formattingtab in PHPRunner.

Set Table: user, Link field: id, Display field: custom expression

concat(firstname,' ',lastname,' - ',email)