Jump to content

time stamp confusion


This topic is 7296 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have a timestamp field that is auto-enter upon the commiting of a record. What i need is a field that returns the previous day of the record. Not 24 hrs. If someone commits it on 4/28/04 at 12:01 AM, then it should say 4/27/04.

I looked through the date functions and didnt see anyway to extract the date from a time stamp field so i used:

LeftWords ( timestamp ; 1 )

this returned the date of the timestamp value. So, i added a - 1 to the calc.

Leftwords(timestamp ; 1) -1

But this gives me a ? in the field. Oddly if i create a two extra fields (three total), i can get it to work:

"Timestamp" ; timestamp format ; auto-enters timestamp

"ExtractDate" ; Calculation-date format ; Leftwords(timestamp ; 1)

"PreviousDate" ; calc.-date format ; ExtractDate - 1

While this will work... why do i have to split the calculation into two fields? In my mind, Leftwords(timestamp ; 1) - 1 should work? that is essentially what i am doing anyway...

Link to comment
Share on other sites

This topic is 7296 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.