Query from 3 tables update 1
everybody!
Can somebody help me to join 3 tables and show the info like HTML table.I'm doing electronic school diary and for the admin panel i need to show one class with students in in and grades on the course.

I've got table 'courses' with 'course_id,class_id,course' rows in it!

I've got table 'grades' with 'grade_id,grade,course_id,student_id' rows in it!

I've got table 'students' with 'student_id,firstname,secondname,lastname,class_id' rows in it!

And i need when choose 'class_id' to be shown something like these:

-------------------------------------------------------------
name               | course1   |   course2  |  course ......|
-------------------------------------------------------------
student1           | 3,5,      |    -       | 2,5           |
-------------------------------------------------------------
student2           | 4         |   2.3      |  -            |
-------------------------------------------------------------


can somebody help me?

P.s.:thanks !
p.s.:ask something,if is not clear :)

Query from 3 tables update 1
===

everybody!
Can somebody help me to join 3 tables and show the info like HTML table.I'm doing electronic school diary and for the admin panel i need to show one class with students in in and grades on the course.

I've got table 'courses' with 'course_id,class_id,course' rows in it!

I've got table 'grades' with 'grade_id,grade,course_id,student_id' rows in it!

I've got table 'students' with 'student_id,firstname,secondname,lastname,class_id' rows in it!

And i need when choose 'class_id' to be shown something like these:

-------------------------------------------------------------
name               | course1   |   course2  |  course ......|
-------------------------------------------------------------
student1           | 3,5,      |    -       | 2,5           |
-------------------------------------------------------------
student2           | 4         |   2.3      |  -            |
-------------------------------------------------------------


can somebody help me?

P.s.:thanks !
p.s.:ask something,if is not clear :)
