Hi All i have a requirement where in i have to get the difference between two incoming dates as an integer value.
Is there anyway we can get it done. If there is even a part solution, please do post it here. I shall be very thankful.
Thanks
Naru.
Date Difference
Moderators: chulett, rschirm, roy
There are lot of ways to get it done. If you make a search you will find a lot of idea.
One simple option is to convert the dates into Julian dates and subtract. The idea is to convert the date into internal or integer format.
JulianDayFromDay() can be used for that.
One simple option is to convert the dates into Julian dates and subtract. The idea is to convert the date into internal or integer format.
JulianDayFromDay() can be used for that.
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
Kumar is right, if you look at the DS help of these functions, you will see that JulianDayFromDate() will return an integer. You can perform this function on your incoming dates and do the substraction. If you just need the difference and not concerned about which date is higher, you can also use Abs() function on the result to get an absolute value.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.