Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Formatting a Date 1

Status
Not open for further replies.

NewbieJDD

MIS
Feb 29, 2012
2
US
Hello,

I am on Crystal Reports 8.5. I was hoping somebody could help me with a date conversion formula. I am trying to convert a date/time field to display the numerical day of the year. For example a date of January 1 =001 and February 6 =037, etc.

I would really appreciate any help.
Let me know if I need to provide any more information.

Thanks,
Jenny
 
Try going into the field explorer->SQL expression->new and see if the dayofyear function is available in the function list, e.g.:

{fn dayofyear(`table`.`date`)}

-LB
 
Thanks lbass, but the function dayofyear isn't available. Any other suggestions?
 
Here's a make your own Julian Date formula:

(date({yourdatetimefield})-
date(year({yourdatetimefield}),1,1))+1
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top