E
Eric G
A main report is based on the following query:
SELECT Detentions.StudentID, Count(Detentions.StudentID) AS
CountOfStudentID, First(Detentions.TeacherID) AS FirstOfTeacherID,
First(Detentions.ReasonID) AS FirstOfReasonID, Students.LastName
FROM Students INNER JOIN Detentions ON Students.StudentID =
Detentions.StudentID
WHERE (((Detentions.Status) Is Null))
GROUP BY Detentions.StudentID, Students.LastName
ORDER BY Students.LastName;
Would someone be able to tell me how I can change the code so that
First(Detentions.ReasonID) AS FirstOfReasonID *excludes* reason 9,
*unless* there are no other reasons except for reason 9 ?
TIA Eric
SELECT Detentions.StudentID, Count(Detentions.StudentID) AS
CountOfStudentID, First(Detentions.TeacherID) AS FirstOfTeacherID,
First(Detentions.ReasonID) AS FirstOfReasonID, Students.LastName
FROM Students INNER JOIN Detentions ON Students.StudentID =
Detentions.StudentID
WHERE (((Detentions.Status) Is Null))
GROUP BY Detentions.StudentID, Students.LastName
ORDER BY Students.LastName;
Would someone be able to tell me how I can change the code so that
First(Detentions.ReasonID) AS FirstOfReasonID *excludes* reason 9,
*unless* there are no other reasons except for reason 9 ?
TIA Eric