Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Formula showing tenths of a month instead of days

Status
Not open for further replies.

cjbrown815

IS-IT--Management
Mar 2, 2006
525
US
Hello,
I have a formula that shows 1.4 MOS (MONTHS). Is ther a way to get the actual month and number of days? thanks

datetimevar d1:={SAMPLE.DATE3};
datetimevar d2:={SAMPLE.DATE1};
totext(Datediff("n",d2,d1)/60 /24 /30,1,"") & " MOS"

-CJ

SQL2005// CRXIr2// XP Pro

"Progress lies not in enhancing what is, but in advancing toward what will be"
-KHALIL GIBRAN 1883-1931
 
This part of the formula gives you difference in minutes

Datediff("n",d2,d1)

Create a new formula with

Datediff("d",d2,d1)

This gives you difference in days.

Ian
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top