Hi
I have an employee table (EMPLOYEE) which has employee start date(ST_DT) and employee end date(END_DT)
I need to calculate the employee duration for each employee which is
End Date - Start date
There are some records which have blank start dates
There are some records which have blank end dates
Again , there are some records where the start date is more than the End date ( This is due to a typographical mistake)
In all these cases I need to report the employee duration as NULL
How can have a single SELECT statement which can give me the employee_duration
I have an employee table (EMPLOYEE) which has employee start date(ST_DT) and employee end date(END_DT)
I need to calculate the employee duration for each employee which is
End Date - Start date
There are some records which have blank start dates
There are some records which have blank end dates
Again , there are some records where the start date is more than the End date ( This is due to a typographical mistake)
In all these cases I need to report the employee duration as NULL
How can have a single SELECT statement which can give me the employee_duration