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

Group Sorting Distinct Count Minimum

Status
Not open for further replies.

socalvelo

Technical User
Jan 29, 2006
128
US
CR 2016
SQL Server
Trying to only display groups with more than one report number

I am reporting traffic accidents in a city based on the number of accidents by location
Most locations only have one report for my time period. I do not want locations with only one report to display
Each accident has a unique report number and a location field

The report is grouped by location, I'm using distinct count formula, and group is sorted in descending order.
My distinct count formula: distinctcount({Report_No},{Report_location})

In the Group Selection Formula Editor I am using this: distinctcount({Report_No})>1 however all of the groups are still displaying
I have used this Group selection formula in other reports, and it has worked.

I think I am missing something simple here. Any help is appreciated

Thanks
Ed


 
Try amending your Group Selection formula to something like:

Code:
DistinctCount({Report_No},{Report_location}) > 1

Hope this helps.

Cheers, Pete
 
Pete,
Thanks this solved the problem. You helped me out with a similar one of these about a month ago and I thought that would work here. Both of these are being used in Sub reports. I appreciate the assistance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top