How to count number of records with each status.

  • Thread starter Thread starter Jane
  • Start date Start date
J

Jane

I'm doing a database for a nightschool and I want to
construct a little summary at the foot of the report which
counts the number os students within each status. For
example:

accepted 10
interview 5
waiting list 3
rejected 4

TOTAL 22

I can do the total bit (=Count[status] in a little
textbox), but how do I do the rest?

Any help appreciated.

Thanks

Jane
 
Jane:

Create a sub report for main report that has a query that groups by status
and counts the statuses.
 
Use the DCount function

=DCount("[filedname]","[query name]","[fieldname]='value'")

Here is one of my examples
=DCount("[Gender]","[Core Services query]","[Gender]='Female'")

Jim
-----Original Message-----
Jane:

Create a sub report for main report that has a query that groups by status
and counts the statuses.
--
Steve Arbaugh
ACG Soft
http://ourworld.compuserve.com/homepages/attac-cg

Jane said:
I'm doing a database for a nightschool and I want to
construct a little summary at the foot of the report which
counts the number os students within each status. For
example:

accepted 10
interview 5
waiting list 3
rejected 4

TOTAL 22

I can do the total bit (=Count[status] in a little
textbox), but how do I do the rest?

Any help appreciated.

Thanks

Jane


.
 
The DCount() solution requires the modification of the report every time you
add or change a Status. Steve's solution will accommodate any number of
Stati and will be more efficient.

--
Duane Hookom
MS Access MVP


Jim/Chris said:
Use the DCount function

=DCount("[filedname]","[query name]","[fieldname]='value'")

Here is one of my examples
=DCount("[Gender]","[Core Services query]","[Gender]='Female'")

Jim
-----Original Message-----
Jane:

Create a sub report for main report that has a query that groups by status
and counts the statuses.
--
Steve Arbaugh
ACG Soft
http://ourworld.compuserve.com/homepages/attac-cg

Jane said:
I'm doing a database for a nightschool and I want to
construct a little summary at the foot of the report which
counts the number os students within each status. For
example:

accepted 10
interview 5
waiting list 3
rejected 4

TOTAL 22

I can do the total bit (=Count[status] in a little
textbox), but how do I do the rest?

Any help appreciated.

Thanks

Jane


.
 
Back
Top