padmapriya patruni

padmapriya patruni

  • NA
  • 74
  • 117.9k

Getting duplicate values

Nov 4 2015 3:53 AM
hi ,
 
I am getting duplicate values . but i used distinct still getting duplicates
 
please help me
SELECT DISTINCT p.EmployeeId,
p.ProjectEmployeeId,
p.StartDate,
p.EndDate,
p.AllocationPercentage,
CONCAT(e.FirstName,' ', e.LastName)AS EmployeeName
FROM projectemployee p
LEFT OUTER JOIN employee e ON p.EmployeeId=e.EmployeeId
WHERE CURDATE() NOT BETWEEN p.StartDate AND p.EndDate OR p.AllocationPercentage <100
ORDER BY e.FirstName ASC;

Answers (4)