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

Count Function

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have a report which shows the fields from two tables, a pub table and a delivery table, under each pub entry on the report there is a list of deliveries which are being made to that specific pub, the problem is that I wish to count the number of pubs on the report, rather than the number of records/deliveries being made, I have tried the count function '=count([ ])' but all this does is count the number of deliveries.

Does anybody have any ideas that would help, it is probably really simple but is driving me crazy
 
As you've discovered, count will only help you with the total number of records. You have 3 options:

- count the distinct pubs behind the scenes in VB
- have a second query (based on the same criteria) which would do the count for you
- as above but add the pub count as an additional column
on your main report query

The last of these is the least elegant but easiest :) Best Regards,
Mike
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top