Counting Records with a certain value

T

The Bard

Hi,

I want to be able to generate a report that counts the number of instances
that the number 2 appears in a field called BookingStatusID in a table called
Booking.

How do I do this please? Do I do in it with a query or directly on a report?
Thanks all~!
Bard
 
K

kingston via AccessMonster.com

If you do it in a report, try the following for the control data source:
DCount("*","Booking","BookingStatusID=2")
Or if you're simply looking for the number 2 anywhere in the field:
DCount("*","Booking","BookingStatusID Like '*2*'")
HTH.
 
Top