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!

count problem using 2 groups

Status
Not open for further replies.

flashes24

IS-IT--Management
Oct 26, 2004
31
US
What I have CR 8.5, using 3 databases type ODBC from same server.

What I have in CR:
Group 2
Names, Sales, Gross Margin
(Need Count HERE of each sale in Group 1)
Group 1
Each sale's details (sale price, cost, added cost)
Details
Breakdown of added cost.

I am trying to get a count in Group 2 of Group 1. I am getting a count of every cost in the Details section. CR only gives me 3 summaries to count and it doesn't return the correct numbers. If I use any regular field I get outrageous counts due to it counting every detail of the record. I can get a count of Group 1. I must have the groups as listed or the information does not come out correctly. Any ideas on how to count Group 2?
 
By the way, when I try different fields of counting I get the total number of detail lines in the report.
 
What are your group 1 and group 2 fields? You should be able to use the following formula:

distinctcount({table.group1field})

...to get the total number of group 1's. You should be able to place this anywhere in the report and get the correct number.

-LB
 
Or try a Running Total. Well worth getting to know, if you don't use them already.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top