Count Records in Report

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I currently have a report of employee time set up for our department. I know
you can use the COUNT fuction to count the total number of records in the
report. However, is there a way to make it a conditional count? For
example, only count the number of records that have hours greater than 8?

Thanks!
 
Sure, set a text box control source in a group or report header or footer
section to:
=Sum(Abs([Hours]>8))
 
AuditorCMM said:
I currently have a report of employee time set up for our department. I know
you can use the COUNT fuction to count the total number of records in the
report. However, is there a way to make it a conditional count? For
example, only count the number of records that have hours greater than 8?


Any of these will do that:

=Count(IIf(hours > 8, 1, Null))

=Sum(IIf(hours > 8, 1, 0))

=Abs(Sum(hours > 8))
 

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

Back
Top