infinitizon
MIS
Hi all,
I have a database (of overtime applications) that looks like this
Notice the date 2012-11-20 is showing 3 times. This is as a result of the fact that the applicant updated the overtime twice.
What I want is a select statement that will show me a result like this
Notice I now have only the last record of the date 2012-11-20 rather than the three dates. How can I call this kind of query.
I know it is something simple but I cant just figure it out right away.
Thanks in advance.
I have a database (of overtime applications) that looks like this
Code:
apply_date | start_time | end_time | overtime_rsn | 1st lvl Sup
2012-11-14 | 13:00:00.000 | 18:00:00.000 | Very good reason | Rejected
2012-11-15 | 16:00:00.000 | 21:00:00.000 | Why do you ask | Not yet Approved
2012-11-20 | 09:00:00.000 | 14:00:00.000 | Good for me | Approved
2012-11-20 | 09:00:00.000 | 14:00:00.000 | Good for me | Approved
2012-11-20 | 09:00:00.000 | 15:00:00.000 | So, so Good for me | Approved
2012-11-21 | 11:00:00.000 | 17:00:00.000 | A reason you must not underestimate | Approved
Notice the date 2012-11-20 is showing 3 times. This is as a result of the fact that the applicant updated the overtime twice.
What I want is a select statement that will show me a result like this
Code:
apply_date | start_time | end_time | overtime_rsn | 1st lvl Sup
2012-11-14 | 13:00:00.000 | 18:00:00.000 | Very good reason | Rejected
2012-11-15 | 16:00:00.000 | 21:00:00.000 | Why do you ask | Not yet Approved
2012-11-20 | 09:00:00.000 | 15:00:00.000 | So, so Good for me | Approved
2012-11-21 | 11:00:00.000 | 17:00:00.000 | A reason you must not underestimate | Approved
Notice I now have only the last record of the date 2012-11-20 rather than the three dates. How can I call this kind of query.
I know it is something simple but I cant just figure it out right away.
Thanks in advance.