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

Formula to calculate Weekend data Only

Status
Not open for further replies.

lndoan

IS-IT--Management
Jun 30, 2005
28
US
The report has page headers labeled has (@hdr01, @hdr02 and so on) which totals up to the number of days per month. It shows W 1 which is wednesday, june 1st, T 2 thursday June 2nd and so on.. the formula for the headers are:

shared paxcount() as string
dim i as number
i = 1
if i>ubound(paxcount) then
formula = ""
else
formula = paxcount(i) + chr(13) + totext(i,0,"")
end if

I want to only calculate data that falls into Saturday and Sunday for the entire month, how would I go about doing this. It is easy to calculate the weekday data but weekend is tricky to think.

 
What does calculate data mean, you want aggregate functions, or?

If you need a summary for the weekend, select a running total and in the evaluate->Use a Formula place something like:

dayofweek({table.date}) in [7,1]

If you only want weekend data in the report, adjust the record selection formula to use the same formula.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top