Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Count or sum unique records in a report's group footer in Access 2

2,211 views
Skip to first unread message

Terri G

unread,
Oct 1, 2009, 6:02:27 PM10/1/09
to
How do I sum or count unique records in a report's group footer in Access
2003? For instance, I have several sections/groups, and there are duplicates
in some of them. I'd like the total to count the number of unique records in
each group on the report. Thanks!

golfinray

unread,
Oct 2, 2009, 11:42:01 AM10/2/09
to
Put a unbound textbox in the footer. The make the control sourse of the
tectbox whatever you need, like =Sum([myfield]) or maybe
=Sum([onefiled]+[anotherfield]) You can have as many of those as you need. To
count records you would simply make it a count like =count([myfield]). Then
you can change the caption of the label to whatever you want.
--
Milton Purdy
ACCESS
State of Arkansas

Duane Hookom

unread,
Oct 2, 2009, 2:51:01 PM10/2/09
to
If you want to count groups, you might need to add a running sum text box in
the group header. For instance, if your report contains orders and order
details but you want to count the number of unique orders, you can't use a
text box in the report footer with a control source like:
=Count(OrderID)
This expression will count orders and details.

You can add a text box in the Order header:
Name: txtOrderCount
Control Source: =1
Running Sum: Over All
Visible: No
Then add a text box in the Report Footer section:
Control Source: =txtOrderCount

--
Duane Hookom
Microsoft Access MVP

0 new messages