Error : An anonymous type cannot have multiple properties with the same name
Here is my codevar employeeTasks = from empTasks in db.EmployeeTasks
join tsk in db.Tasks on empTasks.Tasks_TaskId equals tsk.TaskId
join emp in db.E_Employee on empTasks.Employee_CreatorID equals emp.EmpID
join emp2 in db.E_Employee on empTasks.Employee_AssigneeID equals emp2.EmpID
join emp3 in db.E_Employee on empTasks.Employee_ReporterID equals emp3.EmpID
where empTasks.EmployeeTaskId == id
select new
{
tsk.TaskId,
emp.EmpID,
emp2.EmpID,
emp3.EmpID,
empTasks.Status
};

Guest UserPosted May 11, 2015, 3:01 AM
CreatorId = emp.EmpID,
You can give each property a specific name, so you avoid the three usages of EmpID.
Jithil JohnPosted May 11, 2015, 4:40 AM