Posted by Mike Kantrowitz on July 13, 2000 6:30 AM
Is there a way that you change a Julian date ex.(2000188) to a regular date? 7/9/00???
Posted by Celia on July 15, 0100 2:39 AM
Summary of Julian date conversions
Summary re conversion of Julian Dates :-
In all of the conversion examples below the date 6 July 2000 has been used and the data for conversion is in cell A1. Also, the formulas assume that the Excel 1900 date system is being used.
Format of Julian dates : yyyyddd or yydd
Value of Julian dates : No. of days since 1 Jan, 4712 BC
Format of Excel dates : Various (e.g. mm/dd/yy)
Value of Excel dates : No. of days from start of Excel date system
Start of 1900 Excel date system : 1 Jan, 1900
Equivalent Julian date value : 2415019
Start of 1904 Excel date system : 1 Jan, 1904
Equivalent Julian date value : 2416480
The first four formulas are based on info at www.cpearson.com)
1.Julian formatted date (2000188) to Excel date (07/09/00)
2.Julian formatted date (00188) to Excel date (07/09/00)
3.Excel date (09/07/00) to Julian formatted date (2000188)
4.Excel date (09/07/00) to Julian formatted date (00188)
5.Julian date value (2451732) to Excel date value (36713)
6. Excel date value (36713) to Julian date value (2451732)
Hope this helps
Posted by Celia on July 15, 0100 2:43 AM
Re: Summary of Julian date conversions
All the dates in the CONVERSION section should read 07/06/00.
Posted by AB on July 14, 0100 7:04 AM
Here's a neat Julian conversion trick I thought you all might appreciate. The magic number is: 1963647
My very brief research of Julian dates revealed that the whole point of the dating system was to be able to subtract two Julian dates to determine the number of days between.
This draws a perfect parallel to the Excel date serial number which was created with the same purpose in mind. (Should we spend time wondering why Julian date values were not used as the Excel serial number for a date?)
If the Julian date for 7/9/00 is:
and the Excel date value for 7/9/00 is:
Then all you need to do to convert a Julian date to an Excel date value is subtract the difference which happens to be: 1963467
So, to convert any Julian date to a regular date just subtract 1963467 from the Julian date and format the resulting Excel date value as a date.
Likewise, to convert a regular date to Julian just add 1963467!
Posted by AB on July 14, 0100 7:09 AM
Looks like I might stand corrected once again.
After some further testing it looks like the previously mentioned technique falls out of sequence...
Oh well, back to the drawing board. :)
Posted by Mike Kantrowitz on July 14, 0100 9:10 AM
Posted by Ryan on July 14, 0100 1:05 PM
Here you go,
This code will only work for the year 2000. The basis of this code is the fact that the Julian dates last 3 digits are the days of this year. So the 36526 that I am adding is the amount of days to the Jan 1, 2000. So if you need a different year, just change the 36526 to a different number that represents say Jan 1, 2001. Hope this helps. Let me know
ActiveCell.Value = Right(ActiveCell.Value,3)+36526,"mm/dd/yy")
Posted by Ryan on July 14, 0100 1:27 PM
NeverMind, i'm still working on it
I guess i never looked at what a julian date was. You're example of 2000188 is actually Mar 24, 764 AD. So either you just gave an example that was not real or your system isn't a julian date. Let me know, but i'll get back to the drawing board.
Posted by Ryan on July 13, 0100 1:27 PM
Assuming the date is in A1 you can use this formula. If you want code, let me know!
Posted by JAF on July 14, 0100 1:39 PM
I've just had a similar problem at work needing to check hundreds of thousands of 8 digit dates from the mainframe to check for invalid dates.
This can be done in a macro, but if you can also do it with a simple formula as follows:
NB: as I am in the UK to me a date of 20000710 would be 10th July 2000. If to you this date would represent 7th October 2000 you'll need to transpose the RIGHTand MIDparts of this formula.
Assuming date in cell A1, in cell B1 type =concatenate(right(a1,2),"/",mid(a2,5,2),"/",left(a2,4)) This will produce a TEXT value of 10/07/2000. If you then multiply that text value by one, it will "transform" into a real date that you can then format whatever way you want.
That's the "quick and dirty" way of doing it. If you want the macro code that I used, drop me an email and I'll send it to you.
Posted by Ivan Moala on July 14, 0100 5:01 PM
I saw this one before, and yes it worked for some
but not all.....I was going to look @ it further,
but time always gets the better of you.
If you find anything further to add......would like
Ivan OOPS! Looks like I might stand corrected once again. After some further testing it looks like the previously mentioned technique falls out of sequence... Oh well, back to the drawing board. :)
Posted by Ada on July 14, 0100 7:58 PM
It depends on how Julian Date is defined
One way of doing it,based upon the "scientific" definition of Julian date, is provided at :-
Posted by Ada on July 14, 0100 8:48 PM
Looks like I might stand corrected once again. After some further testing it looks like the previously mentioned technique falls out of sequence... Oh well, back to the drawing board. :)
I think your method didn't work because you were using a different counting system for the Julian date versus the count system for the Excel date.
The Julian date for 9 July, 2000 is 2451735 (not 1963647).
The Julian Date for 31 Dec, 1899 is 2415019.
To arrive at the"Excel" date for 9 July 2000, subtract the second number from the first number and you get the value of the "Excel" date.