I need to count how many of each I have...

K

Kelvin Beaton

I have a report with a field called "Tasks". The fields Tasks is in the
Detail section of the report. It is grouped by the Client's name.
In that field there are a number of codes that could appear in the field.
"FF" and "EP" are two of them.
I want to have a count on my report that tells me how many "FF" or "EP" I
have.
The report is already grouped by each client and I want to know how may FF's
or EP's each client has had.

I can't see how to count if it's a certain value in a field.

Could someone get me going in the right direction?

Thanks in advance!

Kelvin
 
D

Duane Hookom

The quick and dirty method is to add a text box in the Client footer with a
control source like:
=Sum(Abs([Tasks]="FF"))
The more robust solution is to use a subreport with a totals query as its
record source. The totals query might look like:
SELECT ClientID, Tasks, Count(*) as NumOf
FROM tblYourTable
GROUP BY ClientID, Tasks;
 
K

Kelvin Beaton

Thanks, I'll give this a try.

Kelvin
Duane Hookom said:
The quick and dirty method is to add a text box in the Client footer with
a
control source like:
=Sum(Abs([Tasks]="FF"))
The more robust solution is to use a subreport with a totals query as its
record source. The totals query might look like:
SELECT ClientID, Tasks, Count(*) as NumOf
FROM tblYourTable
GROUP BY ClientID, Tasks;
--
Duane Hookom
Microsoft Access MVP


Kelvin Beaton said:
I have a report with a field called "Tasks". The fields Tasks is in the
Detail section of the report. It is grouped by the Client's name.
In that field there are a number of codes that could appear in the field.
"FF" and "EP" are two of them.
I want to have a count on my report that tells me how many "FF" or "EP" I
have.
The report is already grouped by each client and I want to know how may
FF's
or EP's each client has had.

I can't see how to count if it's a certain value in a field.

Could someone get me going in the right direction?

Thanks in advance!

Kelvin
 
Top