Subject | RE: [firebird-support] Number of months between dates |
---|---|
Author | Raigo |
Post date | 2004-05-12T12:12:44Z |
>Or is the difference between 3 march and 20 Jan = 2 months?Almost. This I am doing for a Payroll+HR program and has to calculate number of months person has been working for calculating how many holiday days to give him/her. If has worked more than 15 days in month it counts for month (this is according to law here). Basically if in starting date day number is <=15 and in ending date day >=15 they count in.
with that example 20 Jan - 3 March, number of months would be 1 (full February, but January and March were less than 15 days).