S
Sandy
I have a database to log annual appraisals. It holds details of each
appraisal, including date, and the year of the appraisal, recorded as
'2005/6', '2006/7' etc. I wish to identify all those who have not had an
appraisal in 2007/8. The SQL below, of course, does not just identify those
people who were appointed before 1 April 2007 and who have not been appraised
in 2007/8. How do I restict it to those people? Any help much appreciated.
Sandy
SELECT tblConsultants.MainSite, tblConsultants.ConsultantStatus, [Surname] &
", " & [Title] & " " & [Initials] AS Name, tblConsultants.StartDate,
tblConsultants.Surname, tblAppraisals.AppraisalYr
FROM tblAppraisers RIGHT JOIN (tblConsultants LEFT JOIN tblAppraisals ON
tblConsultants.ConsultantID = tblAppraisals.ConsultantID) ON
tblAppraisers.AppraiserID = tblAppraisals.AppraiserID
WHERE (((tblConsultants.ConsultantStatus)="Current") AND
((tblConsultants.StartDate)<#4/1/2007#) AND ((Exists (SELECT ConsultantID
FROM tblAppraisals
WHERE tblAppraisals.AppraisalYr<>"2007/8"))=True))
ORDER BY tblConsultants.MainSite, [Surname] & ", " & [Title] & " " &
[Initials];
appraisal, including date, and the year of the appraisal, recorded as
'2005/6', '2006/7' etc. I wish to identify all those who have not had an
appraisal in 2007/8. The SQL below, of course, does not just identify those
people who were appointed before 1 April 2007 and who have not been appraised
in 2007/8. How do I restict it to those people? Any help much appreciated.
Sandy
SELECT tblConsultants.MainSite, tblConsultants.ConsultantStatus, [Surname] &
", " & [Title] & " " & [Initials] AS Name, tblConsultants.StartDate,
tblConsultants.Surname, tblAppraisals.AppraisalYr
FROM tblAppraisers RIGHT JOIN (tblConsultants LEFT JOIN tblAppraisals ON
tblConsultants.ConsultantID = tblAppraisals.ConsultantID) ON
tblAppraisers.AppraiserID = tblAppraisals.AppraiserID
WHERE (((tblConsultants.ConsultantStatus)="Current") AND
((tblConsultants.StartDate)<#4/1/2007#) AND ((Exists (SELECT ConsultantID
FROM tblAppraisals
WHERE tblAppraisals.AppraisalYr<>"2007/8"))=True))
ORDER BY tblConsultants.MainSite, [Surname] & ", " & [Title] & " " &
[Initials];