EmployeeID int PK
TrainingRequirementID int Pk
EmployeeID int Fk
I need to return only those Employees who do not have a specific TrainingRequirementID (97) in the EmpTrainingRequirements table.
I have tried several methods but can't seem to get the correct return. Any ideas?
select LastName as Employee,
FROM Employees e
LEFT OUTER JOIN
EmpTrainingRequirements tr ON e.EmployeeID = tr.EmployeeID
where NOT EXISTS (Select * FROM EmpTrainingRequirements where TrainingRequirementID = 97)