sql advice

Chris Sheffield cmsheffield at gmail.com
Tue Jan 24 08:19:42 CST 2006


Unfortunately, no.  I had tried this very thing just before seeing  
your post.  It's as if by applying the SchoolYear='2005' part, it's  
only returning teachers and classes that have students in that year,  
even though it seems like it should return all teachers and classes  
regardless.  I'm missing the key somewhere.


On Jan 24, 2006, at 7:49 AM, Sims, John wrote:

> SELECT Teachers.FirstName, Teachers.LastName, Classes.ClassName,
> Classes.Reading, Students.FirstName, Students.LastName,
> StudentYear.Grade, Teachers.Type, Teachers.RecID
> FROM Teachers, Classes, Students, StudentClass, StudentYear
> WHERE Teachers.RecID*=Classes.TeacherPtr
> AND Classes.RecID*=StudetClass.ClassPtr
> AND StudentClass.StudentYearPtr*=StudentYear.RecID
> AND StudentYear.StudentPtr*=Students.RecID
> AND StudentYear.SchoolYear='2005'
> AND Teachers.Active=1
>
> This should give you all Teachers, all Classes as long as a Teacher is
> assigned to the class, and then the other info you are looking for.

------------------------------------------
Chris Sheffield
Read Naturally
The Fluency Company
http://www.readnaturally.com
------------------------------------------




More information about the Valentina mailing list