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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calculating & Grouping all Friday Dates from now to Year-end

Status
Not open for further replies.
Jun 16, 2000
199
US
Hi. I am on version 8.0 and wanted to know if there was a way to do this. I need to calculate all the Fridays from now until the end of the year, just basing it on currentdate and not on a date in any of the tables in my report. I want to be able to group these calculated dates & then compare information from my database based on the calculated date.

The reason that I want to do this is that I am having is that if there is nothing reported in my database in a week, CR ignores that week & prints the next one when it is grouped. I need to have all weeks accounted - even if 0.

Can you tell me how to do this without creating a separate table listing out all the Friday dates?

I hope this makes sense. Thanks for your help!

Angela
 
Hmm, I'd try to take care of this in the database. In SQL Server I'd use a table-valued function to link to instead of creating an actual table like you mentioned. A list of Fridays until the end of the year is small, so it should never take long to generate.
 
I just wrote an article on the ways to report on data that isn't in the database, giving you your options. You can read the article at:

Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top