I am using SQL Server. I have two tables employees
and employees entry times
.
I am joining these tables using a LEFT OUTER JOIN
. But I want to get the last input value for each employee(Last entered date).
Summary purpose
- Select all employee. If there is no input value corresponding to employee return null.
- If there are much input value corresponding, select last entered date
How do I do this?
The problem I'm having is exponentially more complex.
So simplified example for understanding;
Table 1 : Employees
Id
Name
Table 2 : Employee_Entry_Times
Id
Time_Entered
Employee_REFER