+ Reply to Thread
Results 1 to 7 of 7

Julian conversion

  1. #1
    Registered User
    Join Date
    02-14-2005
    Posts
    3

    Julian conversion

    I am wondering if anyone has written a macro or has developed a formula that will convert a Julian time into a more understandable format? Thanks in advance.

    S4E

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    What exactly do you mean?

    Can't you just use formatting to show the time as you want?

  3. #3
    Forum Expert swatsp0p's Avatar
    Join Date
    10-07-2004
    Location
    Kentucky, USA
    MS-Off Ver
    Excel 2010
    Posts
    1,545
    There are several possible formats for a "Julian" date. Some common ones are:

    2005031 (Jan 31, 2005)
    05031
    5031
    03105
    0312005

    The formula to decode this, of course, depends on the format being used.

    Example: For a code as 5031 for Jan 31, 2005 in cell D5:

    =DATEVALUE("1/1/"&LEFT(D5,1))+RIGHT(D5,3)-1 in a cell formatted as Date m/d/yy returns 1/31/05

    See also "Julian Date" in Excel Help

    HTH
    Bruce
    The older I get, the better I used to be.
    USA

  4. #4
    Registered User
    Join Date
    02-02-2005
    Posts
    35

    Julian Dates

    I assume by julian date you mean the number of the day within the year
    1 to 365 (non leap year)

    eg. J 32 is 1 Feb 2005

    There are two conventions for this on a leap year
    one is 29 Feb is J 366
    the other easier to handle version is
    29 Feb is 60 and 31 Dec becomes J 366

    The second convention allow you to add the Julian date onto the last date of the previous year to get the date in this year

    eg. =A1 + Datevalue("31 Dec 2004)

    formated as Date

    Hope this helps RES

  5. #5
    Registered User
    Join Date
    02-14-2005
    Posts
    3
    Quote Originally Posted by Norie
    What exactly do you mean?

    Can't you just use formatting to show the time as you want?
    One of the fields in the database that I am querying is displayed in seconds based on the Julian date starting on 1/1/1970 (e.g. 1107773696). I am trying to convert this field into a more readable format (e.g. 13:30:55).

    S4E

  6. #6
    Registered User
    Join Date
    02-14-2005
    Posts
    3

    Found a formula

    I was able to locate a formula that converts the seconds into date (25569+(T/86400)-(5/24)).

    T=the number of seconds since 1/1/1970.

    5/24=sets time to EST.

    Thanks for your assistance.

  7. #7
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    Glad you found a solution.

    By the way do you actually mean Gregorian rather than Julian.

    I thought the convention these days (and for a few centuries) has been to use the Gregorian calendar.

+ 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