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

Refreshing for Mon-Fri 1

Status
Not open for further replies.

TheMagikWand

Technical User
Aug 11, 2003
35
0
0
US
hey guys/gals,
i am currently working on a report(ver.8.5) for my company and am having some problems getting the right data to show up.
my problem is this:
the report i have,is supposed togenerate data for all of the "charges" our company has made over the previous week. however i dont know how to select the data to just get the previous week (mon-fri) without actually selecting each date individually.
is there any way i can make a formula or change and option to enable only data from the previous weeks monday through friday to show up??
 
Crystal has a LastFullWeek function that will get the last full week (Sunday to Saturday). You can use it in your Record Selection Formula like this in order to always get the previous week's data:

{Table.DateInvoiced} in LastFullWeek

-dave
 
thanks for the tip, but our office is open 6 days a week, and we only need the records for 5 of them, will that function just use monday - friday or will sat be included as well??

thanks in advance
BUD
 
You can exclude Saturday by using vidru's formula and adding and Datepart("w", {Table.DateInvoiced}) <> 7.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
 
Or use:

dayofweek({table.date}) in 2 to 6

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top