In Report Count "YES"

A

Ady

Hi There

I have a report that lists many rows of Welsh3000 as either YES or NO. In
the report footer I wish to total up all of the "YES". I have tried SUM and
COUNT and DSUM and DCOUNT but I am getting nowhere.

Any help offered will be most appreciated.

Thank you in advance.

Ady
 
R

Rick Brandt

Ady said:
Hi There

I have a report that lists many rows of Welsh3000 as either YES or
NO. In the report footer I wish to total up all of the "YES". I have
tried SUM and COUNT and DSUM and DCOUNT but I am getting nowhere.

Any help offered will be most appreciated.

Is it a Yes/No field or a Text field containing "Yes" and "No" strings?

The Yes/No DataType store true as negative one and false as zero so the
following will give you the count of Yes records...

=Abs(Sum([FieldName]))

If you are using a Text field then...

=Sum(IIf([FieldName]="Yes",1,0))
 
A

Ady

The formula you suggested:
=Sum(IIf([FieldName]="Yes",1,0))

Was successful!

Many thanks!

Ady



Rick Brandt said:
Ady said:
Hi There

I have a report that lists many rows of Welsh3000 as either YES or
NO. In the report footer I wish to total up all of the "YES". I have
tried SUM and COUNT and DSUM and DCOUNT but I am getting nowhere.

Any help offered will be most appreciated.

Is it a Yes/No field or a Text field containing "Yes" and "No" strings?

The Yes/No DataType store true as negative one and false as zero so the
following will give you the count of Yes records...

=Abs(Sum([FieldName]))

If you are using a Text field then...

=Sum(IIf([FieldName]="Yes",1,0))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top