Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a formula in my script to calculate the number of months between [field_start_date] and the reload date. The issue is that is rounding up to the next month. EG. 11.2 months between two dates is rounding this to 12. How can I stop the rounding??
Formula:
((year(reloadtime())*12)+month(reloadtime())) - (((year(field_start_date)*12)+month(field_start_date) as Number_Months,
Please help! Thanks.
Can you give an example, which dates are you using to get the 11.2 months?
So, if you don't want to see 12 months, would you rather see 11 months or are you looking to see 11.2 months? Right now the way you expression is written, it is giving you difference between two dates in months. It can give you 12 (like it is) or 11 (by subtracting 1 from it)... but to get .2 will be tricky because for .2 I am assuming you have 6 days, but then do you divide this by 30 or 31 or even 29/28 for Feb? How do you determine the number of days in a month? or you can say 11 months and 6 days?