Newbies johnthompson Posted November 15, 2002 Newbies Posted November 15, 2002 We use a database to track subscribers to an annual service. Using two fields showing the date started and the date ended, I want to be able to calculate the number of days to the expiry date of the service (showing a minus value if the expiry date has passed). I tried the following, but obviously this fails when the start and end dates span end of year (ie start 4/12/02 end 4/12/03) DayofYear(Ad ended) - DayofYear(Today) Anyone got the solution?
LiveOak Posted November 15, 2002 Posted November 15, 2002 Days (calculation, number) = Ad ended - Status(CurrentDate) Subtracting two dates always gives a number result in days. Unlike "Today", Status(CurentDate) doesn't recalculate every time you open the file, only when needed. -bd
Newbies johnthompson Posted November 21, 2002 Author Newbies Posted November 21, 2002 Thanks for the rapid response. Unfortunately I am still getting incorrect results even using your formula. The Ad ended field is a date field and the "days to go" field is a number field. Yet I have a record showing an ad end of tomorrow's date but the number 7 showing in the days to go field!
BobWeaver Posted November 21, 2002 Posted November 21, 2002 You need to make the calculation field unstored.
Recommended Posts
This topic is 8141 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now