Hi all,
I have a table of employee sickness / absence records with the following structure and data:
I have figure out how to write a query which displays the number of days taken for each sickness (END_DATE minus START_DATE).
My problem is that I would to write a query to display the number of days taken for each of the 12 months of the year.
In the example of Employee 4 their sickness spans two different months, I can't get my head around how to produce the correct result which should look like:-
The only way I can think of doing it is by recording each day of sick individually rather than just the start and end days?
ANY input / comments / observations would be greatfully received!
Thanks
I have a table of employee sickness / absence records with the following structure and data:
I have figure out how to write a query which displays the number of days taken for each sickness (END_DATE minus START_DATE).
My problem is that I would to write a query to display the number of days taken for each of the 12 months of the year.
In the example of Employee 4 their sickness spans two different months, I can't get my head around how to produce the correct result which should look like:-
The only way I can think of doing it is by recording each day of sick individually rather than just the start and end days?
ANY input / comments / observations would be greatfully received!
Thanks
Last edited: