Julian Date or Other Code Date

coffeeman

Registered User.
Local time
Today, 16:49
Joined
Oct 13, 2008
Messages
58
I am curious if there is a way to put in a production date in an entry on a form and have a cell auto calculate a julian date or a specific code date for a customer.

for example, today's production date would be 11/26/08. The Julian Date would be Yddd - Y('last digit year of date produced'), ddd('Julian day of year')

8331 - the 331st day of 2008.

Can someone help me with this?

I basically need this information to come up on the top of a report to let me know the julian date of the items produced that day.

Thanks
 
Not an easy way to do it, no function as far as I know... but I have never used Julian dates before...

It is easy enough to calculate what you want YYxxx where xxx is the day of the year.
This function
year(date()) & date() - dateserial(year(date()),1,0)
returns 2008331

So...
?int(mid(year(date()) & date() - dateserial(year(date()),1,0),2))
8331
 
Where do I enter this in?
 
You enter it in the query window as an expresion
JulianDate: Formula

Or

JulianDate: int(mid(year(date()) & date() - dateserial(year(date()),1,0),2))

@Pat
No sorry, DDD = two letter day, i.e. FR for friday for today.
 
It seems that Datepart is good "for something" afterall....

Although my function does the same... Datepart does look cleaner.
 

Users who are viewing this thread

Back
Top Bottom