quietfulness
New member
- Joined
- Jul 13, 2004
- Messages
- 3
- Programming Experience
- 1-3
Good day..
How do i computer date intervals.
For example, i want to get the year and month interval between between 05/08/2002 and todays date.. so i used datediff(dateinterval.year,d1,d2) and datediff(dateinterval.month,d1,d2).
The year interval returned is correct, however the month returned all the month, resulting to 30 months... im expecting a month interval of 6.
is the month or day interval of datediff counts from the start..? if so is there any functions that i could use to get the actual month and day intervals..?
any help would be greatly appreciated.
thnx very much
How do i computer date intervals.
For example, i want to get the year and month interval between between 05/08/2002 and todays date.. so i used datediff(dateinterval.year,d1,d2) and datediff(dateinterval.month,d1,d2).
The year interval returned is correct, however the month returned all the month, resulting to 30 months... im expecting a month interval of 6.
is the month or day interval of datediff counts from the start..? if so is there any functions that i could use to get the actual month and day intervals..?
any help would be greatly appreciated.
thnx very much