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!

Number of occurences formula 1

Status
Not open for further replies.

stevesd

Technical User
Dec 26, 2000
74
US
I would like to summarize a long list of account/transaction dates. The summary would be:
Number of accounts with 1 to 3 occurrences: ###
Number of accounts with 4 or more occurrences: ###

I do have running totals built to do a distinct count to give me the number of accounts doing business, but when I tried to (lamely) get the above summaries, I ran into the "formula cannot be created" stopper. I must be thinking about this incorrectly somehow. How does one get such a count? The detail records are sorted by account number, by the way.
 
Hi Stevesd...

Question...what makes an occurence?

ChiTownDivaus [ponytails2]
 
A detail record printing for an account. In other words, when I select a record with my record selection parameters, it is an occurrence. In life, it means the customer has placed an order. some will place several a day, while others will place many a day, others only once.
 
First group on {table.AcctNo}.

Then create a running total using a distinct count on {table.AcctNo}, evaluate using a formula:

count({table.AcctNo},{table.AcctNo}) in 1 to 3

Reset never if you want results at the report level, or on change of a higher order group, if you want results at that level.

For the second running total, just change the formula to ">= 4".

These must be displayed in the Report Footer or in a higher order Group Footer, depending on your needs.

-LB
 
thanks very much, lbass.
the totals are true.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top