+ Reply to Thread
Results 1 to 2 of 2

Converting second counter to date

  1. #1
    Registered User
    Join Date
    08-01-2006
    Posts
    5

    Converting second counter to date

    I have a field that records the date as the number of seconds since January 1, 1970.
    It is 10 digits.

    12:00:01 am on 1/1/1970 would appear as 9 zeros and a 1.

    12:01:00 on 1/1/1970 would appear as 8 zeros, a six and then a zero (60 seconds).

    I would like to convert this to a date. mm/dd/yyyy hh:ss would be the ideal, but I'm flexible.

    Any ideas?

  2. #2
    Forum Contributor
    Join Date
    07-05-2006
    Location
    Canada
    MS-Off Ver
    2003, 2007
    Posts
    581
    Quote Originally Posted by carriex3
    I have a field that records the date as the number of seconds since January 1, 1970.
    It is 10 digits.

    12:00:01 am on 1/1/1970 would appear as 9 zeros and a 1.

    12:01:00 on 1/1/1970 would appear as 8 zeros, a six and then a zero (60 seconds).

    I would like to convert this to a date. mm/dd/yyyy hh:ss would be the ideal, but I'm flexible.

    Any ideas?
    Fairly simple. Use 1/1/1970 as the base date/time, and add your value divided by (24*60*60).

    ie. if you have the base value 1/1/1970 12:00:00 AM in A1, your coded time in A2, put the following in A3:
    =A1 + A2/(24*60*60)

    HTH,
    Scott

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1