Forum home » Delegate support and help forum » Microsoft Access Training and help » Counting in reports
Counting in reports
Resolved · Medium Priority · Version 2007
Counting in reports
I have created a query qStaff that generates a list of dates [date] and staff names [worker]. I wish to create a field in a report that counts the number of time one particular member of staff appears (e.g. Fred Bloggs) in that list. What should go in Expression builder to do this?Also what is the expression if I wish to do the same with another employee (e.g. Bill Smith) and subtract it from the first value?
Are these SQL statements?
Many thanks, Gary Heather
For upcoming training course dates see: Pricing & availability
RE: Counting in reports
Hi GaryThanks for your question
I think a Grouped summation query will solve your first problem
Create a query with the staff field in twice. (They should be the only two fields in the query)
Then click the sigma button to add the grouping options. In the "group by" column in the second staff field change the setting to count, and run the query.
As to your second problem, I'm not sure that this can easily be achieved in an Access query. I suggest exporting the ungrouped query into excel and building a pivot table. I will however explore things further and if I find a soloution I will repost here
Reagrds
Stephen
RE: Counting in reports
Thanks for the prompt reply Stephen however it doesnt solve the issue of date parameters nor how I select the data that I want in the report. Do you know of any books/manuals/courses that might cover this sort of thing.Gary
|
|
» Forum post: Watch Window |



Course updates

