Count selected records

P

pow67

In my report, [PRIMARY INFO], I am trying to count the number of records
where [CITY] = Deerfield.

I have tried several combinations such as:

=Count([PRIMARY INFO].CITY Like "Deerfield")

but this counts all records except null.

Thanks in advance.
CW
 
T

tina

-----Original Message-----
In my report, [PRIMARY INFO], I am trying to count the number of records
where [CITY] = Deerfield.

I have tried several combinations such as:

=Count([PRIMARY INFO].CITY Like "Deerfield")

but this counts all records except null.

Thanks in advance.
CW
.
you could try something like this:

=Sum(IIf([CITY]="Deerfield",1,0))

hth
 
T

Tom

You can use DCOUNT to do this =DCOUNT("FIELDNAME","TABLENAME",""FIELDNAME =
'deerfield'")
 

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