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!

Last7DaysToYesterday 1

Status
Not open for further replies.

kyderby

ISP
Jan 11, 2008
2
US
I have Crystal Reports X, and would like to do a Select expert function on a DateTime field that is essentially the Last 7 Days to Yesterday.

You might think they would have that function, but alas it appears they do not.

The Last7Days funtion would include today, the LastFullWeek would be Sun-Sat of the last full week.

And AllDatestoYesterday is well ALL dates, not just a week to yesterday.

Can anyone think how I might be able to do this in perhaps another way?

Thanks,

kyderby
 
Use:

{table.date} in currentdate-8 to currentdate-1

You are in the wrong forum. For questions like this, try forum767 or forum149.

-LB
 
Thank you most kindly.

I suppose if I would learn some SQL this would all be cake...!

kyderby
 
Slightly off-topic, but if your working week runs Monday to Sunday (rather than Sunday to Saturday), use:

{table.date} in minimum(lastfullweek)+1 to maximum(lastfullweek)+1
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top