Forum Discussion
MarkShnier__You
2 years agoQrew Legend
QuickBase knows what the current date and time is and certainly we can have a formula to calculate the time between the current time in any date time field.
But in your case you want to compare the current date and time to affixed date. What time of day would you want to use for that? Like 12 o'clock noon for example?
------------------------------
Mark Shnier (Your Quickbase Coach)
mark.shnier@gmail.com
------------------------------
But in your case you want to compare the current date and time to affixed date. What time of day would you want to use for that? Like 12 o'clock noon for example?
------------------------------
Mark Shnier (Your Quickbase Coach)
mark.shnier@gmail.com
------------------------------
- ChristopherAngu2 years agoQrew MemberThank you for the quick response I really appreciate it. And my apologies for not explaining it too well. So my "date" field gets dates imported through CSV files which are the dates that our service began to our customers. In the spreadsheet we currently have a formula that takes the date of which service started and displays how many months have passed based on todays date since our service started to said customer.
So I was trying to find a way to display the duration that has passed between the date field we enter and today's date in months. I was able to calculate the amount of days not months.
Thank you!
------------------------------
Christopher Angulo
------------------------------- MarkShnier__You2 years agoQrew LegendI posted a better response below.
------------------------------
Mark Shnier (Your Quickbase Coach)
mark.shnier@gmail.com
------------------------------- MarkShnier__You2 years agoQrew LegendActually this one is probably better to use.
var date SD=[MY Date Field];
var date ED=Today();
(Year($ED)-Year($SD)-1)*12 // start off with 12 times the number of fully completed years
+If(Month($ED)>=Month($SD),12,0) //add 12 months if the last year was fully completed
+ If((Month($ED)>=Month($SD)),Month($ED)-Month($SD),12+Month($ED)-Month($SD)) // add the number of months between the month numbers.
-If(Day($ED)<Day($SD),1,0) // but if the day did not catch up to the start date's day number, then subtract 1.
------------------------------
Mark Shnier (Your Quickbase Coach)
mark.shnier@gmail.com
------------------------------
Related Content
- 3 months ago
- 2 months ago
- 26 days ago
- 2 months ago
- 2 months ago